Fix YAML formatting in several REST tests
This commit is contained in:
parent
71aa807acd
commit
389d365697
|
@ -22,8 +22,7 @@ Test reset index settings:
|
|||
- do:
|
||||
indices.get_settings:
|
||||
flat_settings: false
|
||||
- is_false:
|
||||
test-index.settings.index\.refresh_interval
|
||||
- is_false: test-index.settings.index\.refresh_interval
|
||||
- do:
|
||||
indices.get_settings:
|
||||
include_defaults: true
|
||||
|
|
|
@ -31,4 +31,5 @@
|
|||
- do:
|
||||
indices.get_mapping:
|
||||
index: test
|
||||
- is_true: test_2 # the name of the index that the alias points to, would be `test` if the index were still there
|
||||
# the name of the index that the alias points to, would be `test` if the index were still there
|
||||
- is_true: test_2
|
||||
|
|
|
@ -21,10 +21,9 @@
|
|||
scroll: 1m
|
||||
sort: foo
|
||||
body:
|
||||
slice: {
|
||||
id: 0,
|
||||
slice:
|
||||
id: 0
|
||||
max: 3
|
||||
}
|
||||
query:
|
||||
match_all: {}
|
||||
|
||||
|
@ -41,10 +40,9 @@
|
|||
size: 1
|
||||
scroll: 1m
|
||||
body:
|
||||
slice: {
|
||||
id: 0,
|
||||
slice:
|
||||
id: 0
|
||||
max: 1025
|
||||
}
|
||||
query:
|
||||
match_all: {}
|
||||
|
||||
|
@ -60,10 +58,9 @@
|
|||
size: 1
|
||||
scroll: 1m
|
||||
body:
|
||||
slice: {
|
||||
id: 0,
|
||||
slice:
|
||||
id: 0
|
||||
max: 1025
|
||||
}
|
||||
query:
|
||||
match_all: {}
|
||||
|
||||
|
|
|
@ -47,30 +47,30 @@ setup:
|
|||
type: test
|
||||
id: 3
|
||||
body: { "str": "bcd" }
|
||||
|
||||
|
||||
- do:
|
||||
indices.refresh: {}
|
||||
|
||||
|
||||
- do:
|
||||
search:
|
||||
body: { "size" : 0, "aggs" : { "str_terms" : { "terms" : { "field" : "str" } } } }
|
||||
|
||||
- match: { hits.total: 3 }
|
||||
|
||||
|
||||
- length: { aggregations.str_terms.buckets: 2 }
|
||||
|
||||
|
||||
- match: { aggregations.str_terms.buckets.0.key: "abc" }
|
||||
|
||||
|
||||
- is_false: aggregations.str_terms.buckets.0.key_as_string
|
||||
|
||||
|
||||
- match: { aggregations.str_terms.buckets.0.doc_count: 2 }
|
||||
|
||||
|
||||
- match: { aggregations.str_terms.buckets.1.key: "bcd" }
|
||||
|
||||
|
||||
- is_false: aggregations.str_terms.buckets.1.key_as_string
|
||||
|
||||
|
||||
- match: { aggregations.str_terms.buckets.1.doc_count: 1 }
|
||||
|
||||
|
||||
---
|
||||
"IP test":
|
||||
- do:
|
||||
|
@ -112,9 +112,9 @@ setup:
|
|||
- match: { aggregations.ip_terms.buckets.0.doc_count: 2 }
|
||||
|
||||
- match: { aggregations.ip_terms.buckets.1.key: "127.0.0.1" }
|
||||
|
||||
|
||||
- is_false: aggregations.ip_terms.buckets.1.key_as_string
|
||||
|
||||
|
||||
- match: { aggregations.ip_terms.buckets.1.doc_count: 1 }
|
||||
|
||||
- do:
|
||||
|
@ -142,7 +142,7 @@ setup:
|
|||
search:
|
||||
body: { "size" : 0, "aggs" : { "ip_terms" : { "terms" : { "field" : "ip", "exclude" : "127.*" } } } }
|
||||
|
||||
|
||||
|
||||
|
||||
---
|
||||
"Boolean test":
|
||||
|
@ -327,7 +327,7 @@ setup:
|
|||
- match: { aggregations.date_terms.buckets.1.key_as_string: "2014-09-01T00:00:00.000Z" }
|
||||
|
||||
- match: { aggregations.date_terms.buckets.1.doc_count: 1 }
|
||||
|
||||
|
||||
- do:
|
||||
search:
|
||||
body: { "size" : 0, "aggs" : { "date_terms" : { "terms" : { "field" : "date", "include" : [ "2016-05-03" ] } } } }
|
||||
|
@ -335,11 +335,11 @@ setup:
|
|||
- match: { hits.total: 3 }
|
||||
|
||||
- length: { aggregations.date_terms.buckets: 1 }
|
||||
|
||||
|
||||
- match: { aggregations.date_terms.buckets.0.key_as_string: "2016-05-03T00:00:00.000Z" }
|
||||
|
||||
- match: { aggregations.date_terms.buckets.0.doc_count: 2 }
|
||||
|
||||
|
||||
- match: { aggregations.date_terms.buckets.0.doc_count: 2 }
|
||||
|
||||
- do:
|
||||
search:
|
||||
body: { "size" : 0, "aggs" : { "date_terms" : { "terms" : { "field" : "date", "exclude" : [ "2016-05-03" ] } } } }
|
||||
|
@ -347,7 +347,7 @@ setup:
|
|||
- match: { hits.total: 3 }
|
||||
|
||||
- length: { aggregations.date_terms.buckets: 1 }
|
||||
|
||||
|
||||
- match: { aggregations.date_terms.buckets.0.key_as_string: "2014-09-01T00:00:00.000Z" }
|
||||
|
||||
- match: { aggregations.date_terms.buckets.0.doc_count: 1 }
|
||||
- match: { aggregations.date_terms.buckets.0.doc_count: 1 }
|
||||
|
|
|
@ -5,19 +5,14 @@ setup:
|
|||
index: test
|
||||
body:
|
||||
mappings:
|
||||
type_1: {
|
||||
properties: {
|
||||
nested_field : {
|
||||
type_1:
|
||||
properties:
|
||||
nested_field:
|
||||
type: nested
|
||||
}
|
||||
}
|
||||
}
|
||||
type_2: {}
|
||||
type_3: {
|
||||
_parent: {
|
||||
type_3:
|
||||
_parent:
|
||||
type: type_2
|
||||
}
|
||||
}
|
||||
|
||||
---
|
||||
"Nested inner hits":
|
||||
|
@ -26,13 +21,8 @@ setup:
|
|||
index: test
|
||||
type: type_1
|
||||
id: 1
|
||||
body: {
|
||||
"nested_field" : [
|
||||
{
|
||||
"foo": "bar"
|
||||
}
|
||||
]
|
||||
}
|
||||
body:
|
||||
"nested_field" : [ { "foo": "bar" } ]
|
||||
|
||||
- do:
|
||||
indices.refresh: {}
|
||||
|
|
|
@ -15,28 +15,33 @@ setup:
|
|||
"suggest_context":
|
||||
"type" : "completion"
|
||||
"contexts":
|
||||
- "name" : "color"
|
||||
-
|
||||
"name" : "color"
|
||||
"type" : "category"
|
||||
"suggest_context_with_path":
|
||||
"type" : "completion"
|
||||
"contexts":
|
||||
- "name" : "color"
|
||||
-
|
||||
"name" : "color"
|
||||
"type" : "category"
|
||||
"path" : "color"
|
||||
"suggest_geo":
|
||||
"type" : "completion"
|
||||
"contexts":
|
||||
- "name" : "location"
|
||||
-
|
||||
"name" : "location"
|
||||
"type" : "geo"
|
||||
"precision" : "5km"
|
||||
"suggest_multi_contexts":
|
||||
"type" : "completion"
|
||||
"contexts":
|
||||
- "name" : "location"
|
||||
-
|
||||
"name" : "location"
|
||||
"type" : "geo"
|
||||
"precision" : "5km"
|
||||
"path" : "location"
|
||||
- "name" : "color"
|
||||
-
|
||||
"name" : "color"
|
||||
"type" : "category"
|
||||
"path" : "color"
|
||||
|
||||
|
|
Loading…
Reference in New Issue