private AssertBuildingHSQueryContext assertProjection(Query query, String fieldName) { return helper.assertThat( query ) .from( SomeEntity.class ) .projecting( fieldName ); }
void projectionTestHelper(String projectionField, Object expectedValue) { helper.assertThat() .from( ExampleEntity.class ) .projecting( projectionField ) .matchesExactlySingleProjections( expectedValue ); }
private void assertSortedResults(Sort sort, int... expectedIds) { helper.assertThat() .from( Person.class ) .sort( sort ) .matchesExactlyIds( expectedIds ); }
private void assertCount(Class<?> entityType, int count) { helper.assertThat().from( entityType ).hasResultSize( count ); }
@Override public ExtendedSearchIntegrator getUninitializedSearchIntegrator() { return searchFactoryHolder.getSearchFactory(); }; }
private AssertBuildingHSQueryContext assertQueryAll(Sort sort) { return helper.assertThat() .from( IndexedEntry.class ) .sort( sort ); }
private AssertBuildingHSQueryContext assertQuery(Query q) { return helper.assertThat( q ).from( ContainerEntity.class ); } }
private void assertStoredValueEquals(Query query, String fieldName, Object expectedValue) { helper.assertThat( query ) .from( Person.class ) .projecting( fieldName ) .matchesExactlySingleProjections( expectedValue ); }
private void assertDocumentsIndexed(int number) { helper.assertThat().from( Quote.class ).hasResultSize( number ); }
private AssertBuildingHSQueryContext assertQuery(Query query, Sort sort) { return helper.assertThat( query ) .from( IndexedEntry.class ) .sort( sort ); }
private void assertSearchMatches(String field) throws ParseException { helper.assertThat( field, "foo" ) .from( Book.class ) .hasResultSize( 0 ); helper.assertThat( field, "lucene" ) .from( Book.class ) .hasResultSize( 1 ); helper.assertThat( field, "null" ) .from( Book.class ) .hasResultSize( 1 ); helper.assertThat() .from( Book.class ) .hasResultSize( 2 ); }
private AssertBuildingHSQueryContext assertQueryAll(Sort sort) { return helper.assertThat().from( IndexedEntry.class ).sort( sort ); }