OpenSearch/rest-api-spec/test/get_watch/10_basic.yaml

48 lines
994 B
YAML
Raw Normal View History

---
"Test get watch api":
- do:
cluster.health:
wait_for_status: green
- do:
put_watch:
id: "my_watch"
body: >
{
"trigger": {
"schedule": {
"hourly": {
"minute": [ 0, 5 ]
}
}
},
"input": {
"simple": {
"payload": {
"send": "yes"
}
}
},
"condition": {
"always_true": {}
},
"actions": [
{
"test_index": {
"index": {
"index": "test",
"type": "test2"
}
}
}
]
}
- match: { _id: "my_watch" }
- match: { created: true }
- do:
get_watch:
id: "my_watch"
- match: { found : true}
- match: { _id: "my_watch" }