Fix new analysis-common yml tests

These tests are broken because I added them with the `yml` extension
and didn't realize that we weren't running tests with that extension
until we merged #24659. I used that extension in anticipation of #24659
but didn't verify that the tests were actually running. Ooops!

Closes #24734
This commit is contained in:
Nik Everett 2017-05-17 07:42:38 -04:00
parent 026e94e6d9
commit 5fc6f17121
2 changed files with 27 additions and 25 deletions

View File

@ -25,7 +25,7 @@
mappings: mappings:
doc: doc:
properties: properties:
body: text:
type: text type: text
analyzer: index analyzer: index
search_analyzer: search search_analyzer: search
@ -43,9 +43,10 @@
body: body:
query: query:
match: match:
text: fox runs text:
operator: AND query: fox runs
- match: {hits.count: 1} operator: AND
- match: {hits.total: 1}
- do: - do:
index: index:
@ -60,6 +61,7 @@
body: body:
query: query:
match: match:
text: fox runs text:
operator: AND query: fox runs
- match: {hits.count: 2} operator: AND
- match: {hits.total: 2}

View File

@ -3,23 +3,23 @@
# because there are no token filters that support payloads in core. # because there are no token filters that support payloads in core.
- do: - do:
indices.create: indices.create:
index: test index: test
body: body:
mappings: settings:
doc: number_of_shards: 1
properties: number_of_replicas: 1
text: analysis:
type: text analyzer:
term_vector: with_positions_offsets_payloads has_payloads:
analyzer: has_payloads tokenizer: standard
settings: filter: [type_as_payload]
number_of_shards: 1 mappings:
number_of_replicas: 1 doc:
analysis: properties:
analyzer: text:
had_payloads: type: text
tokenizer: standard term_vector: with_positions_offsets_payloads
filter: [type_as_payload] analyzer: has_payloads
- do: - do:
index: index:
@ -37,4 +37,4 @@
id: 1 id: 1
payloads: true payloads: true
- match: {term_vectors.text.field_statistics.sum_doc_freq: 5} - match: {term_vectors.text.field_statistics.sum_doc_freq: 5}
- match: {term_vectors.text.terms.brown.tokens.0.payload: 10} - match: {term_vectors.text.terms.brown.tokens.0.payload: PEFMUEhBTlVNPg==}