415416417418419420421422423424425426
SolrQuery q = new SolrQuery().setQuery("*:*").addField("*").addField("score"); // try { QueryResponse r = otherClient.query(q); assertEquals(0, r.getResults().getNumFound()); } catch (Exception ex) { ex.printStackTrace(); }
463464465466467468469470
fail(); } SolrQuery q = new SolrQuery().setQuery("uuid:4a15da95-f8aa-4039-ba49-f057d23004fa"); QueryResponse r = otherClient.query(q); assertEquals(1, r.getResults().getNumFound()); }
473474475476477478479480
public void testAllUUIDSearch() throws Exception { SolrQuery q = new SolrQuery().setQuery("uuid:[* TO *]"); QueryResponse r = otherClient.query(q); assertEquals(1, r.getResults().getNumFound()); }
544545546547548549550551552553554555
SolrQuery q = new SolrQuery().setQuery("*:*").addField("*").addField("score"); try { QueryResponse r = otherClient.query(q); assertEquals(27, r.getResults().getNumFound()); } catch (Exception ex) { ex.printStackTrace(); }
559560561562563564565566567
public void testAllUUIDSearchAgain() throws Exception { SolrQuery q = new SolrQuery().setQuery("uuid:[* TO *]"); QueryResponse r = otherClient.query(q); assertEquals(27, r.getResults().getNumFound()); }
569570571572573574575576
@Test public void testAllMessageTypeSearch() throws Exception { SolrQuery q = new SolrQuery().setQuery("messageType:[* TO *]"); QueryResponse r = otherClient.query(q); assertEquals(27, r.getResults().getNumFound()); }
579580581582583584585586
public void testAllMessageTypeTransportSearch() throws Exception { SolrQuery q = new SolrQuery().setQuery("messageType:Transport"); QueryResponse r = otherClient.query(q); assertEquals(3, r.getResults().getNumFound()); }
599600601602603604605606607608609610611
SolrQuery q = new SolrQuery().setQuery("*:*").addField("*").addField("score"); try { QueryResponse r = otherClient.query(q); assertEquals(29, r.getResults().getNumFound()); } catch (Exception ex) { ex.printStackTrace(); }
652653654655656657658659660
} otherClient.commit(); SolrQuery q = new SolrQuery().setQuery("*:*"); QueryResponse r = otherClient.query(q); assertEquals(0, r.getResults().getNumFound()); }
762763764765766767768769770771772773
SolrQuery q = new SolrQuery().setQuery("*:*"); try { QueryResponse r = otherClient.query(q); assertEquals(42, r.getResults().getNumFound()); } catch (Exception ex) { ex.printStackTrace(); }