File tree Expand file tree Collapse file tree 1 file changed +27
-1
lines changed
rest-api-spec/src/main/resources/rest-api-spec/test/search Expand file tree Collapse file tree 1 file changed +27
-1
lines changed Original file line number Diff line number Diff line change 22setup :
33 - do :
44 indices.create :
5- index : test
5+ index : test
66 body :
77 mappings :
88 properties :
@@ -13,6 +13,19 @@ setup:
1313 my_ip :
1414 type : ip
1515 ignore_malformed : true
16+ - do :
17+ indices.create :
18+ index : index_level_setting
19+ body :
20+ settings :
21+ index.mapping.ignore_malformed : true
22+ mappings :
23+ properties :
24+ my_date :
25+ type : date
26+ ignore_malformed : false
27+ my_ip :
28+ type : ip
1629
1730 - do :
1831 index :
4053
4154 - do :
4255 search :
56+ index : test
4357 rest_total_hits_as_int : true
4458 body : { query: { exists: { "field": "_ignored" } } }
4559
5064
5165 - do :
5266 search :
67+ index : test
5368 rest_total_hits_as_int : true
5469 body : { query: { term: { "_ignored": "my_date" } } }
5570
6075
6176 - do :
6277 search :
78+ index : test
6379 rest_total_hits_as_int : true
6480 body : { query: { terms: { "_ignored": [ "my_date", "my_ip" ] } } }
6581
7086
7187 - do :
7288 search :
89+ index : test
7390 rest_total_hits_as_int : true
7491 body : { query: { ids: { "values": [ "3" ] } } }
7592
@@ -81,9 +98,18 @@ setup:
8198
8299 - do :
83100 search :
101+ index : test
84102 rest_total_hits_as_int : true
85103 stored_fields : [ "my_date" ]
86104 body : { query: { ids: { "values": [ "3" ] } } }
87105
88106 - length : { hits.hits: 1 }
89107 - is_true : hits.hits.0._ignored
108+
109+ ---
110+ " field-level setting shall override index-level setting " :
111+ - do :
112+ catch : /failed to parse field \[my_date\] of type \[date\]/
113+ index :
114+ index : index_level_setting
115+ body : { "my_date": "bar", "my_ip": "quux" }
You can’t perform that action at this time.
0 commit comments