@Test
public void buildTest() throws Exception {

    @SuppressWarnings("unchecked")
    FilterDBObjectBuilder filterDBObjectBuilder = new FilterDBObjectBuilder(false, Collections.EMPTY_LIST);
    DBObject dbObject = QueryBuilder.start(COLUMN_1).greaterThanEquals(5).get();
    Whitebox.setInternalState(filterDBObjectBuilder, "filterQuery", dbObject);
    Whitebox.setInternalState(filterDBObjectBuilder, "useAggregation", false);
    DBObject filterQuery = filterDBObjectBuilder.build();
    assertNotNull("The filter query is null", filterQuery);
    assertEquals("There should be a query only over 1 field", 1, filterQuery.keySet().size());
    assertTrue("The query should contain a clause about" + COLUMN_1, filterQuery.containsField(COLUMN_1));
    DBObject condition = (DBObject) filterQuery.get(COLUMN_1);
    assertTrue("The query does not contain '$gte'", condition.containsField("$gte"));
    assertEquals("The value of '$gte' key should be 5", 5, condition.get("$gte"));
}