MustNotFieldSearchParam implements SearchParam { public String getQuery() { return "-" + fieldName + ":" + value + ""; } MustNotFieldSearchParam(String fieldName, String value); String getQuery(); Query getLuceneQuery(); @Override boolean equals(Object obj); @Override int hashCode(); @Override String toString();  }
@Test public void testGetQuery_1() throws Exception { MustNotFieldSearchParam fixture = new MustNotFieldSearchParam("", ""); String result = fixture.getQuery(); assertEquals("-:", result); }