### Question:
APIProcessConnector extends ConsoleAPI<ProcessConnectorItem> implements
        APIHasGet<ProcessConnectorItem>,
        APIHasSearch<ProcessConnectorItem> { @Override public ItemSearchResult<ProcessConnectorItem> search(final int page, final int resultsByPage, final String search, final String orders, final Map<String, String> filters) { if (MapUtil.isBlank(filters, ATTRIBUTE_PROCESS_ID)) { throw new APIFilterMandatoryException(ATTRIBUTE_PROCESS_ID); } return super.search(page, resultsByPage, search, orders, filters); }  @Override String defineDefaultSearchOrder(); @Override ItemSearchResult<ProcessConnectorItem> search(final int page, final int resultsByPage, final String search, final String orders,
            final Map<String, String> filters);  }### Answer:
@Test(expected = APIFilterMandatoryException.class) public void whenSearchingFilterProcessIdIsMandatory() throws Exception { this.apiProcessConnector.search(0, 10, null, null, EMPTY_MAP); }
@Test public void searchIsDoneWhenProcessIdFilterIsSet() throws Exception { final Map<String, String> filters = new HashMap<String, String>(); filters.put(ProcessConnectorItem.ATTRIBUTE_PROCESS_ID, "1"); this.apiProcessConnector.search(0, 10, null, null, filters); verify(this.processConnectorDatastore).search(0, 10, null, null, filters); }