From 9e6e85a0a44af474d9b4e00f547af73d14402a37 Mon Sep 17 00:00:00 2001 From: kkewwei Date: Fri, 2 Aug 2024 02:44:02 +0800 Subject: [PATCH] fix rest api spec tests Signed-off-by: kkewwei --- .../test/index/110_constant_keyword.yml | 35 ++++++++++++++----- 1 file changed, 26 insertions(+), 9 deletions(-) diff --git a/rest-api-spec/src/main/resources/rest-api-spec/test/index/110_constant_keyword.yml b/rest-api-spec/src/main/resources/rest-api-spec/test/index/110_constant_keyword.yml index 0cd0c2917f699..38d447b6427af 100644 --- a/rest-api-spec/src/main/resources/rest-api-spec/test/index/110_constant_keyword.yml +++ b/rest-api-spec/src/main/resources/rest-api-spec/test/index/110_constant_keyword.yml @@ -6,11 +6,10 @@ # - Verify document count # - Search rangeQuery and regexpQuery # - Delete indices when connection is teardown - -"Mappings and Supported queries": +setup: - skip: - version: " - 2.16.99" - reason: "fixed in 2.17.0" + version: " - 2.15.99" + reason: "fixed in 2.16.0" # Create indices with constant_keyword field type - do: @@ -63,6 +62,23 @@ indices.refresh: index: [test, test1] +--- +# Delete Index when connection is teardown +teardown: + - skip: + version: " - 2.15.99" + reason: "fixed in 2.16.0" + + - do: + indices.delete: + index: test,test1 + +--- +"Mappings": + - skip: + version: " - 2.15.99" + reason: "fixed in 2.16.0" + # Check mapping - do: indices.get_mapping: @@ -97,6 +113,12 @@ - length: { hits.hits: 1 } - match: { hits.hits.0._source.genre: "d3efault" } +--- +"Queries": + - skip: + version: " - 2.16.99" + reason: "fixed in 2.17.0" + # Test rangeQuery - do: search: @@ -313,8 +335,3 @@ } - length: { hits.hits: 0 } - - # Delete Index when connection is teardown - - do: - indices.delete: - index: test,test1