public static <K>void verifyQueryKeys(LuceneQuery<K,Object> query,K... expectedKeys) throws LuceneQueryException {
  Set<K> expectedKeySet=new HashSet<>(Arrays.asList(expectedKeys));
  Set<K> actualKeySet=new HashSet<>(query.findKeys());
  assertEquals(expectedKeySet,actualKeySet);
}

public static < K > void verifyQueryKeys ( LuceneQuery < K , Object > query , K ... expectedKeys ) throws LuceneQueryException { Set < K > expectedKeySet = new HashSet < > ( Arrays . asList ( expectedKeys ) ) ; Set < K > actualKeySet = new HashSet < > ( query . findKeys ( ) ) ; assertEquals ( expectedKeySet , actualKeySet ) ; }
verify that a query returns the expected list of keys . ordering is ignored .
