diff --git a/rest-api-spec/src/main/resources/rest-api-spec/test/field_stats/10_basics.yaml b/rest-api-spec/src/main/resources/rest-api-spec/test/field_stats/10_basics.yaml index 165ed9f469c..ff284216f0f 100644 --- a/rest-api-spec/src/main/resources/rest-api-spec/test/field_stats/10_basics.yaml +++ b/rest-api-spec/src/main/resources/rest-api-spec/test/field_stats/10_basics.yaml @@ -1,5 +1,15 @@ ---- -"Basic field stats": +setup: + - do: + indices.create: + index: test_1 + body: + mappings: + test: + properties: + foo: + type: string + number: + type: long - do: index: index: test_1 @@ -10,6 +20,8 @@ - do: indices.refresh: {} +--- +"Basic field stats": - do: field_stats: index: test_1 @@ -28,16 +40,6 @@ --- "Basic field stats with level set to indices": - - do: - index: - index: test_1 - type: test - id: id_1 - body: { foo: "bar", number: 123 } - - - do: - indices.refresh: {} - - do: field_stats: index: test_1 @@ -57,15 +59,6 @@ --- "Field stats with filtering": - - do: - index: - index: test_1 - type: test - id: id_1 - body: { foo: "bar", number: 123 } - - - do: - indices.refresh: {} - do: field_stats: