@Test
    public void test() throws IOException {
        EmptyQueryBuilder query = QueryBuilders.query(
                FilterBuilders.boolFilter(
                        FilterBuilders.filter(
                                FilterBuilders.termFilter("organizationId", "ORG_ID"),
                                FilterBuilders.termFilter("userId", "USER")))
                );
        String actual = query.string();
        Assert.assertEquals("{\"query\":{\"bool\":{\"filter\":[{\"term\":{\"organizationId\":\"ORG_ID\"}},{\"term\":{\"userId\":\"USER\"}}]}}}", actual);
    }
Test method for {@link io.apiman.manager.api.es.util.BoolFilterBuilder#doXContent(io.apiman.manager.api.es.util.XContentBuilder)}.
manager/api/es/src/test/java/io/apiman/manager/api/es/util/FilteredQueryBuilderTest.java