Tests: Added some tests for proper 404 responses on watch actions (elastic/elasticsearch#4620)

Relates elastic/elasticsearch#4616 elastic/elasticsearch#4617

Original commit: elastic/x-pack-elasticsearch@7f73792507
This commit is contained in:
Alexander Reelsen 2017-01-20 12:01:44 +01:00 committed by GitHub
parent 630b5fd836
commit 8011912ce7
3 changed files with 37 additions and 0 deletions

View File

@ -50,3 +50,13 @@
id: "my_watch" id: "my_watch"
- match: { found: true } - match: { found: true }
---
"Non existent watch returns 404":
- do:
cluster.health:
wait_for_status: yellow
- do:
xpack.watcher.ack_watch:
watch_id: "non-existent-watch"
catch: missing

View File

@ -75,3 +75,19 @@
id: "my_watch" id: "my_watch"
- match: { found: true } - match: { found: true }
---
"Non existent watch returns 404":
- do:
cluster.health:
wait_for_status: yellow
- do:
xpack.watcher.activate_watch:
watch_id: "non-existent-watch"
catch: missing
- do:
xpack.watcher.deactivate_watch:
watch_id: "non-existent-watch"
catch: missing

View File

@ -42,3 +42,14 @@
xpack.watcher.delete_watch: xpack.watcher.delete_watch:
id: "my_watch" id: "my_watch"
- match: { found: true } - match: { found: true }
---
"Non existent watch returns 404":
- do:
cluster.health:
wait_for_status: yellow
- do:
xpack.watcher.delete_watch:
id: "non-existent-watch"
catch: missing