diff --git a/build-tools-internal/src/integTest/groovy/org/elasticsearch/gradle/internal/test/rest/YamlRestCompatTestPluginFuncTest.groovy b/build-tools-internal/src/integTest/groovy/org/elasticsearch/gradle/internal/test/rest/YamlRestCompatTestPluginFuncTest.groovy index b94f8c1f58e8e..b75cb393a2c61 100644 --- a/build-tools-internal/src/integTest/groovy/org/elasticsearch/gradle/internal/test/rest/YamlRestCompatTestPluginFuncTest.groovy +++ b/build-tools-internal/src/integTest/groovy/org/elasticsearch/gradle/internal/test/rest/YamlRestCompatTestPluginFuncTest.groovy @@ -82,7 +82,8 @@ class YamlRestCompatTestPluginFuncTest extends AbstractRestResourcesFuncTest { String wrongTest = "wrong_version.yml" String additionalTest = "additional_test.yml" setupRestResources([wrongApi], [wrongTest]) //setups up resources for current version, which should not be used for this test - addRestTestsToProject([additionalTest], "yamlRestCompatTest") + String sourceSetName = "yamlRestTestV" + compatibleVersion + "Compat" + addRestTestsToProject([additionalTest], sourceSetName) //intentionally adding to yamlRestTest source set since the .classes are copied from there file("src/yamlRestTest/java/MockIT.java") << "import org.junit.Test;class MockIT { @Test public void doNothing() { }}" @@ -107,17 +108,17 @@ class YamlRestCompatTestPluginFuncTest extends AbstractRestResourcesFuncTest { file("/build/${testIntermediateDir}/original/rest-api-spec/test/" + test).exists() file("/build/${testIntermediateDir}/transformed/rest-api-spec/test/" + test).exists() file("/build/${testIntermediateDir}/transformed/rest-api-spec/test/" + test).text.contains("headers") //transformation adds this - file("/build/resources/yamlRestCompatTest/rest-api-spec/test/" + additionalTest).exists() + file("/build/resources/${sourceSetName}/rest-api-spec/test/" + additionalTest).exists() //additionalTest is not copied from the prior version, and thus not in the intermediate directory, nor transformed - file("/build/resources/yamlRestCompatTest/" + testIntermediateDir + "/rest-api-spec/test/" + additionalTest).exists() == false - file("/build/resources/yamlRestCompatTest/rest-api-spec/test/" + additionalTest).text.contains("headers") == false + file("/build/resources/${sourceSetName}/" + testIntermediateDir + "/rest-api-spec/test/" + additionalTest).exists() == false + file("/build/resources/${sourceSetName}/rest-api-spec/test/" + additionalTest).text.contains("headers") == false file("/build/classes/java/yamlRestTest/MockIT.class").exists() //The "standard" runner is used to execute the compat test - file("/build/resources/yamlRestCompatTest/rest-api-spec/api/" + wrongApi).exists() == false - file("/build/resources/yamlRestCompatTest/" + testIntermediateDir + "/rest-api-spec/test/" + wrongTest).exists() == false - file("/build/resources/yamlRestCompatTest/rest-api-spec/test/" + wrongTest).exists() == false + file("/build/resources/${sourceSetName}/rest-api-spec/api/" + wrongApi).exists() == false + file("/build/resources/${sourceSetName}/" + testIntermediateDir + "/rest-api-spec/test/" + wrongTest).exists() == false + file("/build/resources/${sourceSetName}/rest-api-spec/test/" + wrongTest).exists() == false result.task(':copyRestApiSpecsTask').outcome == TaskOutcome.NO_SOURCE result.task(':copyYamlTestsTask').outcome == TaskOutcome.NO_SOURCE diff --git a/build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/rest/compat/YamlRestCompatTestPlugin.java b/build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/rest/compat/YamlRestCompatTestPlugin.java index 7559c11d69962..87bd5f78e70bc 100644 --- a/build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/rest/compat/YamlRestCompatTestPlugin.java +++ b/build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/rest/compat/YamlRestCompatTestPlugin.java @@ -8,17 +8,17 @@ package org.elasticsearch.gradle.internal.rest.compat; -import org.elasticsearch.gradle.internal.ElasticsearchJavaBasePlugin; import org.elasticsearch.gradle.Version; import org.elasticsearch.gradle.VersionProperties; +import org.elasticsearch.gradle.internal.ElasticsearchJavaBasePlugin; import org.elasticsearch.gradle.internal.test.RestIntegTestTask; import org.elasticsearch.gradle.internal.test.RestTestBasePlugin; import org.elasticsearch.gradle.internal.test.rest.CopyRestApiTask; import org.elasticsearch.gradle.internal.test.rest.CopyRestTestsTask; +import org.elasticsearch.gradle.internal.test.rest.InternalYamlRestTestPlugin; import org.elasticsearch.gradle.internal.test.rest.RestResourcesExtension; import org.elasticsearch.gradle.internal.test.rest.RestResourcesPlugin; import org.elasticsearch.gradle.internal.test.rest.RestTestUtil; -import org.elasticsearch.gradle.internal.test.rest.InternalYamlRestTestPlugin; import org.elasticsearch.gradle.testclusters.TestClustersPlugin; import org.elasticsearch.gradle.util.GradleUtils; import org.gradle.api.Plugin; @@ -46,21 +46,22 @@ * Apply this plugin to run the YAML based REST tests from a prior major version against this version's cluster. */ public class YamlRestCompatTestPlugin implements Plugin { + public static final String BWC_MINOR_CONFIG_NAME = "bwcMinor"; private static final String REST_COMPAT_CHECK_TASK_NAME = "checkRestCompat"; private static final String COMPATIBILITY_APIS_CONFIGURATION = "restCompatSpecs"; private static final String COMPATIBILITY_TESTS_CONFIGURATION = "restCompatTests"; - private static final String SOURCE_SET_NAME = "yamlRestCompatTest"; private static final Path RELATIVE_API_PATH = Path.of("rest-api-spec/api"); private static final Path RELATIVE_TEST_PATH = Path.of("rest-api-spec/test"); private static final Path RELATIVE_REST_API_RESOURCES = Path.of("rest-api-spec/src/main/resources"); private static final Path RELATIVE_REST_XPACK_RESOURCES = Path.of("x-pack/plugin/src/test/resources"); private static final Path RELATIVE_REST_PROJECT_RESOURCES = Path.of("src/yamlRestTest/resources"); - public static final String BWC_MINOR_CONFIG_NAME = "bwcMinor"; + private static final int COMPATIBLE_VERSION = Version.fromString(VersionProperties.getVersions().get("elasticsearch")).getMajor() - 1; + private static final String SOURCE_SET_NAME = "yamlRestTestV" + COMPATIBLE_VERSION + "Compat"; @Override public void apply(Project project) { - final int compatibleVersion = Version.fromString(VersionProperties.getVersions().get("elasticsearch")).getMajor() - 1; - final Path compatRestResourcesDir = Path.of("restResources").resolve("v" + compatibleVersion); + + final Path compatRestResourcesDir = Path.of("restResources").resolve("v" + COMPATIBLE_VERSION); final Path compatSpecsDir = compatRestResourcesDir.resolve("yamlSpecs"); final Path compatTestsDir = compatRestResourcesDir.resolve("yamlTests"); @@ -160,7 +161,7 @@ public void apply(Project project) { // transform the copied tests task TaskProvider transformCompatTestTask = project.getTasks() - .register("yamlRestTestV" + compatibleVersion + "CompatTransform", RestCompatTestTransformTask.class, task -> { + .register("yamlRestTestV" + COMPATIBLE_VERSION + "CompatTransform", RestCompatTestTransformTask.class, task -> { task.getSourceDirectory().set(copyCompatYamlTestTask.flatMap(CopyRestTestsTask::getOutputResourceDir)); task.getOutputDirectory() .set(project.getLayout().getBuildDirectory().dir(compatTestsDir.resolve("transformed").toString())); @@ -191,7 +192,7 @@ public void apply(Project project) { .named(RestResourcesPlugin.COPY_YAML_TESTS_TASK) .flatMap(CopyRestTestsTask::getOutputResourceDir); - String testTaskName = "yamlRestTestV" + compatibleVersion + "CompatTest"; + String testTaskName = "yamlRestTestV" + COMPATIBLE_VERSION + "CompatTest"; // setup the test task Provider yamlRestCompatTestTask = RestTestUtil.registerTestTask(project, yamlCompatTestSourceSet, testTaskName); @@ -207,11 +208,13 @@ public void apply(Project project) { .minus(project.files(originalYamlSpecsDir)) .minus(project.files(originalYamlTestsDir)) ); + // run compatibility tests after "normal" tests testTask.mustRunAfter(project.getTasks().named(InternalYamlRestTestPlugin.SOURCE_SET_NAME)); testTask.onlyIf(t -> isEnabled(project)); }); + setupTestDependenciesDefaults(project, yamlCompatTestSourceSet); // setup IDE diff --git a/rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/api/cluster.post_voting_config_exclusions_with_node_name_part.json b/rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/api/cluster.post_voting_config_exclusions_with_node_name_part.json similarity index 100% rename from rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/api/cluster.post_voting_config_exclusions_with_node_name_part.json rename to rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/api/cluster.post_voting_config_exclusions_with_node_name_part.json diff --git a/rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/api/indices.put_template_with_param.json b/rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/api/indices.put_template_with_param.json similarity index 100% rename from rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/api/indices.put_template_with_param.json rename to rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/api/indices.put_template_with_param.json diff --git a/rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/cluster.voting_config_exclusions/10_basic_compat.yml b/rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/cluster.voting_config_exclusions/10_basic_compat.yml similarity index 100% rename from rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/cluster.voting_config_exclusions/10_basic_compat.yml rename to rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/cluster.voting_config_exclusions/10_basic_compat.yml diff --git a/rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/indices.deprecated.upgrade/10_basic_upgrade.yml b/rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/indices.deprecated.upgrade/10_basic_upgrade.yml similarity index 100% rename from rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/indices.deprecated.upgrade/10_basic_upgrade.yml rename to rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/indices.deprecated.upgrade/10_basic_upgrade.yml diff --git a/rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/indices.put_template/10_basic_compat.yml b/rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/indices.put_template/10_basic_compat.yml similarity index 100% rename from rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/indices.put_template/10_basic_compat.yml rename to rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/indices.put_template/10_basic_compat.yml diff --git a/rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/nodes.hot_threads/10_basic_compat.yml b/rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/nodes.hot_threads/10_basic_compat.yml similarity index 100% rename from rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/nodes.hot_threads/10_basic_compat.yml rename to rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/nodes.hot_threads/10_basic_compat.yml diff --git a/rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/search/10_cutoff_frequency.yml b/rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/search/10_cutoff_frequency.yml similarity index 100% rename from rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/search/10_cutoff_frequency.yml rename to rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/search/10_cutoff_frequency.yml diff --git a/rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/search/10_type_query.yml b/rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/search/10_type_query.yml similarity index 100% rename from rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/search/10_type_query.yml rename to rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/search/10_type_query.yml diff --git a/rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/search/sort/10_nested_path_filter.yml b/rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/search/sort/10_nested_path_filter.yml similarity index 100% rename from rest-api-spec/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/search/sort/10_nested_path_filter.yml rename to rest-api-spec/src/yamlRestTestV7Compat/resources/rest-api-spec/test/search/sort/10_nested_path_filter.yml diff --git a/test/framework/src/main/java/org/elasticsearch/test/rest/yaml/ESClientYamlSuiteTestCase.java b/test/framework/src/main/java/org/elasticsearch/test/rest/yaml/ESClientYamlSuiteTestCase.java index fcbd29f5f0e12..4c1407cf1744f 100644 --- a/test/framework/src/main/java/org/elasticsearch/test/rest/yaml/ESClientYamlSuiteTestCase.java +++ b/test/framework/src/main/java/org/elasticsearch/test/rest/yaml/ESClientYamlSuiteTestCase.java @@ -11,6 +11,8 @@ import com.carrotsearch.randomizedtesting.RandomizedTest; import com.carrotsearch.randomizedtesting.annotations.TimeoutSuite; import org.apache.http.HttpHost; +import org.apache.logging.log4j.LogManager; +import org.apache.logging.log4j.Logger; import org.apache.lucene.util.TimeUnits; import org.elasticsearch.Version; import org.elasticsearch.client.Node; @@ -42,6 +44,7 @@ import java.nio.file.Path; import java.util.ArrayList; import java.util.Arrays; +import java.util.Collections; import java.util.Comparator; import java.util.HashMap; import java.util.HashSet; @@ -52,6 +55,7 @@ import java.util.Set; import java.util.SortedSet; import java.util.TreeSet; +import java.util.stream.Collectors; /** * Runs a suite of yaml tests shared with all the official Elasticsearch @@ -270,7 +274,15 @@ private static void addSuite(Path root, Path file, Map> files) filesSet = new HashSet<>(); files.put(groupName, filesSet); } + filesSet.add(file); + List fileNames = filesSet.stream().map(p -> p.getFileName().toString()).collect(Collectors.toList()); + if (Collections.frequency(fileNames, file.getFileName().toString()) > 1) { + Logger logger = LogManager.getLogger(ESClientYamlSuiteTestCase.class); + logger.warn("Found duplicate test name [" + groupName + "/" + file.getFileName() + "] on the class path. " + + "This can result in class loader dependent execution commands and reproduction commands " + + "(will add #2 to one of the test names dependent on the classloading order)"); + } } private static String[] resolvePathsProperty(String propertyName, String defaultValue) { diff --git a/x-pack/plugin/build.gradle b/x-pack/plugin/build.gradle index 7acd20167747d..e08da7bff5895 100644 --- a/x-pack/plugin/build.gradle +++ b/x-pack/plugin/build.gradle @@ -1,6 +1,7 @@ import org.elasticsearch.gradle.internal.info.BuildParams import org.elasticsearch.gradle.util.GradleUtils import org.elasticsearch.gradle.internal.test.RestIntegTestTask +import org.elasticsearch.gradle.VersionProperties apply plugin: 'elasticsearch.internal-yaml-rest-test' apply plugin: 'elasticsearch.yaml-rest-compat-test' @@ -18,7 +19,8 @@ dependencies { // let the yamlRestTests see the classpath of test GradleUtils.extendSourceSet(project, "test", "yamlRestTest", tasks.named("yamlRestTest")) -GradleUtils.extendSourceSet(project, "test", "yamlRestCompatTest") +int compatVersion = VersionProperties.getElasticsearchVersion().getMajor() - 1; +GradleUtils.extendSourceSet(project, "test", "yamlRestTestV${compatVersion}Compat") restResources { restApi { diff --git a/x-pack/plugin/spatial/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/geo_shape/10_compat_geo_shape_with_types.yml b/x-pack/plugin/spatial/src/yamlRestTestV7Compat/resources/rest-api-spec/test/geo_shape/10_compat_geo_shape_with_types.yml similarity index 100% rename from x-pack/plugin/spatial/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/geo_shape/10_compat_geo_shape_with_types.yml rename to x-pack/plugin/spatial/src/yamlRestTestV7Compat/resources/rest-api-spec/test/geo_shape/10_compat_geo_shape_with_types.yml diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.delete.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.delete.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.delete.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.delete.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.get.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.get.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.get.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.get.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.get_basic_status.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.get_basic_status.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.get_basic_status.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.get_basic_status.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.get_trial_status.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.get_trial_status.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.get_trial_status.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.get_trial_status.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.post.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.post.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.post.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.post.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.post_start_basic.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.post_start_basic.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.post_start_basic.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.post_start_basic.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.post_start_trial.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.post_start_trial.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-license.post_start_trial.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-license.post_start_trial.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-migration.deprecations.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-migration.deprecations.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-migration.deprecations.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-migration.deprecations.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.close_job.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.close_job.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.close_job.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.close_job.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_calendar.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_calendar.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_calendar.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_calendar.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_calendar_event.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_calendar_event.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_calendar_event.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_calendar_event.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_calendar_job.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_calendar_job.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_calendar_job.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_calendar_job.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_datafeed.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_datafeed.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_datafeed.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_datafeed.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_expired_data.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_expired_data.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_expired_data.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_expired_data.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_filter.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_filter.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_filter.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_filter.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_forecast.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_forecast.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_forecast.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_forecast.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_job.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_job.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_job.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_job.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_model_snapshot.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_model_snapshot.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.delete_model_snapshot.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.delete_model_snapshot.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.flush_job.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.flush_job.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.flush_job.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.flush_job.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.forecast.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.forecast.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.forecast.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.forecast.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_buckets.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_buckets.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_buckets.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_buckets.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_calendar_events.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_calendar_events.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_calendar_events.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_calendar_events.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_calendars.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_calendars.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_calendars.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_calendars.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_categories.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_categories.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_categories.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_categories.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_datafeed_stats.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_datafeed_stats.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_datafeed_stats.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_datafeed_stats.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_datafeeds.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_datafeeds.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_datafeeds.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_datafeeds.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_filters.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_filters.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_filters.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_filters.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_influencers.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_influencers.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_influencers.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_influencers.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_job_stats.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_job_stats.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_job_stats.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_job_stats.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_jobs.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_jobs.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_jobs.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_jobs.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_model_snapshots.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_model_snapshots.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_model_snapshots.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_model_snapshots.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_overall_buckets.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_overall_buckets.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_overall_buckets.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_overall_buckets.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_records.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_records.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.get_records.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.get_records.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.info.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.info.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.info.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.info.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.open_job.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.open_job.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.open_job.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.open_job.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.post_calendar_events.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.post_calendar_events.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.post_calendar_events.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.post_calendar_events.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.post_data.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.post_data.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.post_data.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.post_data.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.preview_datafeed.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.preview_datafeed.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.preview_datafeed.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.preview_datafeed.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.put_calendar.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.put_calendar.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.put_calendar.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.put_calendar.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.put_calendar_job.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.put_calendar_job.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.put_calendar_job.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.put_calendar_job.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.put_datafeed.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.put_datafeed.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.put_datafeed.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.put_datafeed.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.put_filter.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.put_filter.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.put_filter.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.put_filter.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.put_job.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.put_job.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.put_job.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.put_job.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.revert_model_snapshot.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.revert_model_snapshot.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.revert_model_snapshot.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.revert_model_snapshot.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.set_upgrade_mode.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.set_upgrade_mode.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.set_upgrade_mode.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.set_upgrade_mode.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.start_datafeed.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.start_datafeed.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.start_datafeed.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.start_datafeed.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.stop_datafeed.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.stop_datafeed.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.stop_datafeed.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.stop_datafeed.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.update_datafeed.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.update_datafeed.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.update_datafeed.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.update_datafeed.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.update_filter.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.update_filter.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.update_filter.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.update_filter.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.update_job.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.update_job.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.update_job.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.update_job.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.update_model_snapshot.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.update_model_snapshot.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.update_model_snapshot.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.update_model_snapshot.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.validate.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.validate.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.validate.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.validate.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.validate_detector.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.validate_detector.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ml.validate_detector.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ml.validate_detector.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-monitoring.bulk.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-monitoring.bulk.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-monitoring.bulk.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-monitoring.bulk.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.delete_job.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.delete_job.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.delete_job.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.delete_job.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.get_jobs.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.get_jobs.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.get_jobs.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.get_jobs.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.get_rollup_caps.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.get_rollup_caps.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.get_rollup_caps.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.get_rollup_caps.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.get_rollup_index_caps.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.get_rollup_index_caps.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.get_rollup_index_caps.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.get_rollup_index_caps.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.put_job.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.put_job.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.put_job.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.put_job.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.start_job.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.start_job.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.start_job.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.start_job.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.stop_job.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.stop_job.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-rollup.stop_job.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-rollup.stop_job.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ssl.certificates.json b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ssl.certificates.json similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-ssl.certificates.json rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-ssl.certificates.json diff --git a/x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/monitoring/bulk/10_basic_compat.yml b/x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/test/monitoring/bulk/10_basic_compat.yml similarity index 100% rename from x-pack/plugin/src/yamlRestCompatTest/resources/rest-api-spec/test/v7compat/monitoring/bulk/10_basic_compat.yml rename to x-pack/plugin/src/yamlRestTestV7Compat/resources/rest-api-spec/test/monitoring/bulk/10_basic_compat.yml diff --git a/x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.ack_watch.json b/x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.ack_watch.json similarity index 100% rename from x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.ack_watch.json rename to x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.ack_watch.json diff --git a/x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.activate_watch.json b/x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.activate_watch.json similarity index 100% rename from x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.activate_watch.json rename to x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.activate_watch.json diff --git a/x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.deactivate_watch.json b/x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.deactivate_watch.json similarity index 100% rename from x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.deactivate_watch.json rename to x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.deactivate_watch.json diff --git a/x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.delete_watch.json b/x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.delete_watch.json similarity index 100% rename from x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.delete_watch.json rename to x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.delete_watch.json diff --git a/x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.execute_watch.json b/x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.execute_watch.json similarity index 100% rename from x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.execute_watch.json rename to x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.execute_watch.json diff --git a/x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.get_watch.json b/x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.get_watch.json similarity index 100% rename from x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.get_watch.json rename to x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.get_watch.json diff --git a/x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.put_watch.json b/x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.put_watch.json similarity index 100% rename from x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.put_watch.json rename to x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.put_watch.json diff --git a/x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.start.json b/x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.start.json similarity index 100% rename from x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.start.json rename to x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.start.json diff --git a/x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.stats.json b/x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.stats.json similarity index 100% rename from x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.stats.json rename to x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.stats.json diff --git a/x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.stop.json b/x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.stop.json similarity index 100% rename from x-pack/plugin/watcher/qa/rest/src/yamlRestCompatTest/resources/rest-api-spec/api/xpack-watcher.stop.json rename to x-pack/plugin/watcher/qa/rest/src/yamlRestTestV7Compat/resources/rest-api-spec/api/xpack-watcher.stop.json