@Test public void queryQmsButNoBlackList() { final QueryResponseData responseData = new QueryResponseData(); final AciErrorException blacklistError = new AciErrorException(); blacklistError.setErrorString(FindQueryExecutor.MISSING_RULE_ERROR); when(queryExecutor.executeQuery(any(), any())).thenThrow(blacklistError).thenReturn(responseData); assertNotNull(findQueryExecutor.executeQuery(new AciParameters(), QueryType.MODIFIED)); }
@Override public QueryResponseData executeQuery( final AciParameters aciParameters, final QueryType queryType ) throws AciErrorException { return executeQueryDiscardingBlacklist(aciParameters, queryType, queryExecutor::executeQuery); }
FindQueryExecutor implements QueryExecutor { @Override public QueryResponseData executeQuery( final AciParameters aciParameters, final QueryType queryType ) throws AciErrorException { return executeQueryDiscardingBlacklist(aciParameters, queryType, queryExecutor::executeQuery); } }
FindQueryExecutor implements QueryExecutor { @Override public QueryResponseData executeQuery( final AciParameters aciParameters, final QueryType queryType ) throws AciErrorException { return executeQueryDiscardingBlacklist(aciParameters, queryType, queryExecutor::executeQuery); } @SuppressWarnings("ConstructorWithTooManyParameters") @Autowired  FindQueryExecutor(
            @Qualifier(QUERY_EXECUTOR_BEAN_NAME) final QueryExecutor queryExecutor
    ); }
FindQueryExecutor implements QueryExecutor { @Override public QueryResponseData executeQuery( final AciParameters aciParameters, final QueryType queryType ) throws AciErrorException { return executeQueryDiscardingBlacklist(aciParameters, queryType, queryExecutor::executeQuery); } @SuppressWarnings("ConstructorWithTooManyParameters") @Autowired  FindQueryExecutor(
            @Qualifier(QUERY_EXECUTOR_BEAN_NAME) final QueryExecutor queryExecutor
    ); @Override boolean performQuery(final QueryType queryType); @Override QueryResponseData executeQuery(
            final AciParameters aciParameters,
            final QueryType queryType
    ); @Override SuggestResponseData executeSuggest(
            final AciParameters aciParameters,
            final QueryType queryType
    ); @Override GetQueryTagValuesResponseData executeGetQueryTagValues(
            final AciParameters aciParameters,
            final QueryType queryType
    ); static R executeQueryDiscardingBlacklist(
            final AciParameters aciParameters,
            final QueryType queryType,
            final BiFunction<AciParameters, QueryType, R> function
    ); }
FindQueryExecutor implements QueryExecutor { @Override public QueryResponseData executeQuery( final AciParameters aciParameters, final QueryType queryType ) throws AciErrorException { return executeQueryDiscardingBlacklist(aciParameters, queryType, queryExecutor::executeQuery); } @SuppressWarnings("ConstructorWithTooManyParameters") @Autowired  FindQueryExecutor(
            @Qualifier(QUERY_EXECUTOR_BEAN_NAME) final QueryExecutor queryExecutor
    ); @Override boolean performQuery(final QueryType queryType); @Override QueryResponseData executeQuery(
            final AciParameters aciParameters,
            final QueryType queryType
    ); @Override SuggestResponseData executeSuggest(
            final AciParameters aciParameters,
            final QueryType queryType
    ); @Override GetQueryTagValuesResponseData executeGetQueryTagValues(
            final AciParameters aciParameters,
            final QueryType queryType
    ); static R executeQueryDiscardingBlacklist(
            final AciParameters aciParameters,
            final QueryType queryType,
            final BiFunction<AciParameters, QueryType, R> function
    );  }