ExecutionErrorListBasicFiltersPresenter extends BasicFiltersPresenter { @Override public void loadFilters() { view.addNumericFilter(constants.Process_Instance_Id(), constants.FilterByProcessInstanceId(), f -> addSearchFilter(f, equalsTo(COLUMN_PROCESS_INST_ID, f.getValue())) ); view.addNumericFilter(constants.JobId(), constants.FilterByJobId(), f -> addSearchFilter(f, equalsTo(COLUMN_JOB_ID, f.getValue())) ); view.addTextFilter(constants.Id(), constants.FilterByErrorId(), f -> addSearchFilter(f, likeTo(COLUMN_ERROR_ID, f.getValue())) ); view.addMultiSelectFilter(constants.Type(), ExecutionErrorTypeConverter.getErrorTypesStrMapping(), f -> addSearchFilterList(COLUMN_ERROR_TYPE, f)); final Map<String, String> acks = new HashMap<>(); final org.jbpm.workbench.common.client.resources.i18n.Constants constants = org.jbpm.workbench.common.client.resources.i18n.Constants.INSTANCE; acks.put("1", constants.Yes()); acks.put("0", constants.No()); view.addSelectFilter(this.constants.Acknowledged(), acks, f -> addSearchFilter(f, equalsTo(COLUMN_ERROR_ACK, Integer.valueOf(f.getValue()))) ); view.addDateRangeFilter(this.constants.ErrorDate(), this.constants.ErrorDatePlaceholder(), true, f -> addSearchFilter(f, between(COLUMN_ERROR_DATE, f.getValue().getStartDate(), f.getValue().getEndDate())) ); }  @Override String getDataSetId(); @Override void loadFilters();  }
@Override @Test public void testLoadFilters() { presenter.loadFilters(); final InOrder inOrder = inOrder(getView()); inOrder.verify(getView()).addNumericFilter(eq(Constants.INSTANCE.Process_Instance_Id()), any(), any()); inOrder.verify(getView()).addNumericFilter(eq(Constants.INSTANCE.JobId()), any(), any()); inOrder.verify(getView()).addTextFilter(eq(Constants.INSTANCE.Id()), any(), any()); inOrder.verify(getView()).addMultiSelectFilter(eq(Constants.INSTANCE.Type()), any(), any()); inOrder.verify(getView()).addSelectFilter(eq(Constants.INSTANCE.Acknowledged()), any(), any()); inOrder.verify(getView()).addDateRangeFilter(eq(Constants.INSTANCE.ErrorDate()), any(), any(), any()); }