Package org.apache.lucene.facet.example.simple

Examples of org.apache.lucene.facet.example.simple.SimpleMain


*/
public class TestSimpleExample extends LuceneTestCase {

  @Test
  public void testSimple () throws Exception {
    ExampleResult res = new SimpleMain().runSimple();
    assertNotNull("Null result!", res);
    assertNotNull("Null facet result!", res.getFacetResults());
    assertEquals("Wrong number of results!",1, res.getFacetResults().size());
    assertEquals("Wrong number of facets!",3, res.getFacetResults().get(0).getNumValidDescendants());
  }
View Full Code Here


   * In drill down test we are drilling down to a facet that appears in a single document.
   * As result, facets that without drill down got count of 2 will now get a count of 1.
   */
  @Test
  public void testDrillDown () throws Exception {
    ExampleResult res = new SimpleMain().runDrillDown();
    assertNotNull("Null result!", res);
    assertNotNull("Null facet result!", res.getFacetResults());
    assertEquals("Wrong number of results!",1, res.getFacetResults().size());
   
    // drill down facet appears in only 1 doc, and that doc has only 2 facets 
View Full Code Here

TOP

Related Classes of org.apache.lucene.facet.example.simple.SimpleMain

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.