use of com.yahoo.searchlib.aggregation.VdsHit in project vespa by vespa-engine.
the class HitConverterTestCase method requireThatVdsHitCanBeConverted.
@Test
public void requireThatVdsHitCanBeConverted() {
HitConverter converter = new HitConverter(new MySearcher(), new Query());
GroupingListHit context = new GroupingListHit(null, new DocsumDefinitionSet(sixtynine()));
VdsHit lowHit = new VdsHit("doc:scheme:", new byte[] { 0x55, 0x55, 0x55, 0x55 }, 1);
lowHit.setContext(context);
Hit hit = converter.toSearchHit("69", lowHit);
assertNotNull(hit);
assertTrue(hit instanceof FastHit);
assertEquals(new Relevance(1), hit.getRelevance());
assertTrue(hit.isFilled("69"));
}
Aggregations