uboness 39f9f53a0a Renamed the status field in the stored watch
was renamed to `_status` so it'll distinct from the other "formal" fields of the watch and also be aligned with the `_status` field that is returned by the Get API.

Also updated the installation docs

Original commit: elastic/x-pack-elasticsearch@1081b75d13
2015-06-25 15:39:19 +02:00

53 lines
1.1 KiB
YAML

---
"Test ack watch api":
- do:
cluster.health:
wait_for_status: yellow
- do:
watcher.put_watch:
id: "my_watch"
master_timeout: "40s"
body: >
{
"trigger" : {
"schedule" : { "cron" : "0 0 0 1 * ? 2099" }
},
"input": {
"simple": {
"payload": {
"send": "yes"
}
}
},
"condition": {
"always": {}
},
"actions": {
"test_index": {
"index": {
"index": "test",
"doc_type": "test2"
}
}
}
}
- match: { _id: "my_watch" }
- do:
cluster.health:
wait_for_status: yellow
- do:
watcher.ack_watch:
watch_id: "my_watch"
- match: { "_status.actions.test_index.ack.state" : "awaits_successful_execution" }
- do:
watcher.delete_watch:
id: "my_watch"
- match: { found: true }