mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-03-27 10:28:28 +00:00
suggest api tests
This commit is contained in:
parent
77fe6f25e2
commit
875de1a5a6
23
rest-api-spec/test/suggest/10_basic.yaml
Normal file
23
rest-api-spec/test/suggest/10_basic.yaml
Normal file
@ -0,0 +1,23 @@
|
||||
---
|
||||
"Basic tests for suggest API":
|
||||
- do:
|
||||
index:
|
||||
index: test
|
||||
type: test
|
||||
id: testing_document
|
||||
body:
|
||||
body: Amsterdam meetup
|
||||
|
||||
- do:
|
||||
indices.refresh: {}
|
||||
|
||||
- do:
|
||||
suggest:
|
||||
body:
|
||||
test_suggestion:
|
||||
text: "The Amsterdma meetpu"
|
||||
term:
|
||||
field: body
|
||||
|
||||
- match: {test_suggestion.0.options.0.text: amsterdam}
|
||||
- match: {test_suggestion.1.options.0.text: meetup}
|
Loading…
x
Reference in New Issue
Block a user