tests: additional prefix facet tests

This commit is contained in:
yonik 2016-02-18 12:19:26 -05:00
parent d8afc3876d
commit 091889cf79
1 changed files with 15 additions and 0 deletions

View File

@ -632,6 +632,21 @@ public class TestJsonFacets extends SolrTestCaseHS {
"'f1':{ 'buckets':[]} } "
);
// test prefix on where field
client.testJQ(params(p, "q", "*:*"
, "json.facet", "{" +
" f1:{${terms} type:terms, field:${where_s}, prefix:N }" +
",f2:{${terms} type:terms, field:${where_s}, prefix:NY }" +
",f3:{${terms} type:terms, field:${where_s}, prefix:NJ }" +
"}"
)
, "facets=={ 'count':6 " +
",f1:{ 'buckets':[ {val:NJ,count:3}, {val:NY,count:2} ]}" +
",f2:{ 'buckets':[ {val:NY,count:2} ]}" +
",f3:{ 'buckets':[ {val:NJ,count:3} ]}" +
" } "
);
//
// missing
//