@Override
      public void run2() throws CacheException {
        Set filter = getFilter(0, 2);

        TestServerQueryFunction func = new TestServerQueryFunction("LDS Server function-2");
        function = new TestQueryFunction("queryFunction");

        for (int i = 0; i < queries.length; i++) {

          QueryUsingFunctionContextDUnitTest test = new QueryUsingFunctionContextDUnitTest();
          ArrayList queryResults2 =
              test.runQueryOnClientUsingFunc(function, PartitionedRegionName1, filter, queries[i]);

          // The Partition Region has 20 buckets with 100 values and key i goes in bucket j=(i%20)
          // So each bucket has 5 keys so for 3 buckets 3*5.
          if (i == 0 && queryResults2.size() != 3 * 5) {
            fail("Result size should have been 15 but was" + queryResults2.size());
          }
        }
      }
Test on PR on one server only using filter.
geode-core/src/distributedTest/java/org/apache/geode/cache/query/dunit/QueryUsingFunctionContextDUnitTest.java