Also adds tests for date fields for match query builder
PR is against the query refactoring branch. Closes #13585
This commit is contained in:
parent
dbaa90a3f8
commit
4096244ec2
|
@ -46,7 +46,11 @@ public class MatchQueryBuilderTests extends AbstractQueryTestCase<MatchQueryBuil
|
|||
|
||||
@Override
|
||||
protected MatchQueryBuilder doCreateTestQueryBuilder() {
|
||||
String fieldName = randomFrom(new String[] { STRING_FIELD_NAME, BOOLEAN_FIELD_NAME, INT_FIELD_NAME, DOUBLE_FIELD_NAME });
|
||||
String fieldName = randomFrom(STRING_FIELD_NAME, BOOLEAN_FIELD_NAME, INT_FIELD_NAME,
|
||||
DOUBLE_FIELD_NAME, DATE_FIELD_NAME);
|
||||
if (fieldName.equals(DATE_FIELD_NAME)) {
|
||||
assumeTrue("test runs only when at least a type is registered", getCurrentTypes().length > 0);
|
||||
}
|
||||
Object value = "";
|
||||
if (fieldName.equals(STRING_FIELD_NAME)) {
|
||||
int terms = randomIntBetween(0, 3);
|
||||
|
|
Loading…
Reference in New Issue