From c16860e901ca00d0f4597fa3e3e737f5733c5c50 Mon Sep 17 00:00:00 2001 From: Chris Earle Date: Wed, 17 Aug 2016 15:35:18 -0400 Subject: [PATCH] Fix Watcher REST test Original commit: elastic/x-pack-elasticsearch@7cb5b08948c856e45150f5e3ce32e02e7267f72b --- .../60_put_watch_with_action_condition.yaml | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/elasticsearch/x-pack/watcher/src/test/resources/rest-api-spec/test/xpack/watcher/put_watch/60_put_watch_with_action_condition.yaml b/elasticsearch/x-pack/watcher/src/test/resources/rest-api-spec/test/xpack/watcher/put_watch/60_put_watch_with_action_condition.yaml index ed9cd5a43c7..b4062d10f0a 100644 --- a/elasticsearch/x-pack/watcher/src/test/resources/rest-api-spec/test/xpack/watcher/put_watch/60_put_watch_with_action_condition.yaml +++ b/elasticsearch/x-pack/watcher/src/test/resources/rest-api-spec/test/xpack/watcher/put_watch/60_put_watch_with_action_condition.yaml @@ -13,9 +13,6 @@ teardown: --- "Test put watch api with action level condition": - -skip: - version: "all" - reason: awaits fix bug URL https://github.com/elastic/x-plugins/issues/3137 - do: xpack.watcher.put_watch: id: "my_watch1" @@ -31,9 +28,7 @@ teardown: }, "input": { "simple": { - "payload": { - "value": 15 - } + "value": 15 } }, "condition": { @@ -42,8 +37,10 @@ teardown: "actions": { "test_index": { "condition": { - "ctx.payload.value": { - "gt": 10 + "compare": { + "ctx.payload.value": { + "lt": 10 + } } }, "index": { @@ -60,4 +57,4 @@ teardown: id: "my_watch1" - match: { found : true} - match: { _id: "my_watch1" } - - match: { watch.actions.test_index.condition.ctx.payload.value.gt: 10 } + - match: { watch.actions.test_index.condition.compare: { "ctx.payload.value": { lt: 10 } } }