diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 52513c42ce5af..76620c208976c 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -412,7 +412,7 @@ known as "transitive" dependencies". should not be shipped with the project because it is "provided" by the runtime somehow. Elasticsearch plugins use this configuration to include dependencies that are bundled with Elasticsearch's server. -
`testCompile`
Code that is on the classpath for compiling tests +
`testImplementation`
Code that is on the classpath for compiling tests that are part of this project but not production code. The canonical example of this is `junit`.
diff --git a/buildSrc/build.gradle b/buildSrc/build.gradle index 56db196ec9e68..6f9bcf7123739 100644 --- a/buildSrc/build.gradle +++ b/buildSrc/build.gradle @@ -122,13 +122,13 @@ dependencies { compile 'org.apache.maven:maven-model:3.6.2' compile 'com.networknt:json-schema-validator:1.0.36' compileOnly "com.puppycrawl.tools:checkstyle:${props.getProperty('checkstyle')}" - testCompile "com.puppycrawl.tools:checkstyle:${props.getProperty('checkstyle')}" + testImplementation "com.puppycrawl.tools:checkstyle:${props.getProperty('checkstyle')}" testFixturesApi "junit:junit:${props.getProperty('junit')}" testFixturesApi "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${props.getProperty('randomizedrunner')}" testFixturesApi gradleApi() testFixturesApi gradleTestKit() - testCompile 'com.github.tomakehurst:wiremock-jre8-standalone:2.23.2' - testCompile 'org.mockito:mockito-core:1.9.5' + testImplementation 'com.github.tomakehurst:wiremock-jre8-standalone:2.23.2' + testImplementation 'org.mockito:mockito-core:1.9.5' minimumRuntimeCompile "junit:junit:${props.getProperty('junit')}" minimumRuntimeCompile localGroovy() minimumRuntimeCompile gradleApi() diff --git a/buildSrc/src/main/groovy/org/elasticsearch/gradle/plugin/PluginBuildPlugin.groovy b/buildSrc/src/main/groovy/org/elasticsearch/gradle/plugin/PluginBuildPlugin.groovy index 9e721496e6999..b5e8d20325701 100644 --- a/buildSrc/src/main/groovy/org/elasticsearch/gradle/plugin/PluginBuildPlugin.groovy +++ b/buildSrc/src/main/groovy/org/elasticsearch/gradle/plugin/PluginBuildPlugin.groovy @@ -165,10 +165,10 @@ class PluginBuildPlugin implements Plugin { project.dependencies { if (BuildParams.internal) { compileOnly project.project(':server') - testCompile project.project(':test:framework') + testImplementation project.project(':test:framework') } else { compileOnly "org.elasticsearch:elasticsearch:${project.versions.elasticsearch}" - testCompile "org.elasticsearch.test:framework:${project.versions.elasticsearch}" + testImplementation "org.elasticsearch.test:framework:${project.versions.elasticsearch}" } // we "upgrade" these optional deps to provided for plugins, since they will run // with a full elasticsearch server that includes optional deps diff --git a/buildSrc/src/main/groovy/org/elasticsearch/gradle/test/StandaloneRestTestPlugin.groovy b/buildSrc/src/main/groovy/org/elasticsearch/gradle/test/StandaloneRestTestPlugin.groovy index a35d01a4bdac0..779ad7618e5e9 100644 --- a/buildSrc/src/main/groovy/org/elasticsearch/gradle/test/StandaloneRestTestPlugin.groovy +++ b/buildSrc/src/main/groovy/org/elasticsearch/gradle/test/StandaloneRestTestPlugin.groovy @@ -83,7 +83,7 @@ class StandaloneRestTestPlugin implements Plugin { // create a compileOnly configuration as others might expect it project.configurations.create("compileOnly") - project.dependencies.add('testCompile', project.project(':test:framework')) + project.dependencies.add('testImplementation', project.project(':test:framework')) EclipseModel eclipse = project.extensions.getByType(EclipseModel) eclipse.classpath.sourceSets = [testSourceSet] diff --git a/buildSrc/src/main/groovy/org/elasticsearch/gradle/test/TestWithDependenciesPlugin.groovy b/buildSrc/src/main/groovy/org/elasticsearch/gradle/test/TestWithDependenciesPlugin.groovy index cbf3f172e620a..d1e8b014c9753 100644 --- a/buildSrc/src/main/groovy/org/elasticsearch/gradle/test/TestWithDependenciesPlugin.groovy +++ b/buildSrc/src/main/groovy/org/elasticsearch/gradle/test/TestWithDependenciesPlugin.groovy @@ -44,7 +44,7 @@ class TestWithDependenciesPlugin implements Plugin { return } - project.configurations.testCompile.dependencies.all { Dependency dep -> + project.configurations.testImplementation.dependencies.all { Dependency dep -> // this closure is run every time a compile dependency is added if (dep instanceof ProjectDependency && dep.dependencyProject.plugins.hasPlugin(PluginBuildPlugin)) { project.gradle.projectsEvaluated { diff --git a/buildSrc/src/main/java/org/elasticsearch/gradle/ElasticsearchJavaPlugin.java b/buildSrc/src/main/java/org/elasticsearch/gradle/ElasticsearchJavaPlugin.java index 3c135ab105ce4..a1190aaa19d94 100644 --- a/buildSrc/src/main/java/org/elasticsearch/gradle/ElasticsearchJavaPlugin.java +++ b/buildSrc/src/main/java/org/elasticsearch/gradle/ElasticsearchJavaPlugin.java @@ -33,6 +33,7 @@ import org.gradle.api.Project; import org.gradle.api.Task; import org.gradle.api.artifacts.Configuration; +import org.gradle.api.artifacts.DependencySet; import org.gradle.api.artifacts.ModuleDependency; import org.gradle.api.artifacts.ProjectDependency; import org.gradle.api.artifacts.ResolutionStrategy; @@ -114,9 +115,24 @@ public void apply(Project project) { public static void configureConfigurations(Project project) { // we want to test compileOnly deps! Configuration compileOnlyConfig = project.getConfigurations().getByName(JavaPlugin.COMPILE_ONLY_CONFIGURATION_NAME); - Configuration testCompileConfig = project.getConfigurations().getByName(JavaPlugin.TEST_COMPILE_CONFIGURATION_NAME); - testCompileConfig.extendsFrom(compileOnlyConfig); - + Configuration testImplementationConfig = project.getConfigurations().getByName(JavaPlugin.TEST_IMPLEMENTATION_CONFIGURATION_NAME); + testImplementationConfig.extendsFrom(compileOnlyConfig); + + // fail on using deprecated testCompile + project.getConfigurations().getByName(JavaPlugin.TEST_COMPILE_CONFIGURATION_NAME).withDependencies(new Action() { + @Override + public void execute(DependencySet dependencies) { + if (dependencies.size() > 0) { + throw new GradleException( + "Usage of configuration " + + JavaPlugin.TEST_COMPILE_CONFIGURATION_NAME + + " is no longer supported. Use " + + JavaPlugin.TEST_IMPLEMENTATION_CONFIGURATION_NAME + + " instead." + ); + } + } + }); // we are not shipping these jars, we act like dumb consumers of these things if (project.getPath().startsWith(":test:fixtures") || project.getPath().equals(":build-tools")) { return; @@ -130,7 +146,7 @@ public static void configureConfigurations(Project project) { configuration.resolutionStrategy(ResolutionStrategy::failOnVersionConflict); }); - // force all dependencies added directly to compile/testCompile to be non-transitive, except for ES itself + // force all dependencies added directly to compile/testImplementation to be non-transitive, except for ES itself Consumer disableTransitiveDeps = configName -> { Configuration config = project.getConfigurations().getByName(configName); config.getDependencies().all(dep -> { @@ -142,9 +158,9 @@ public static void configureConfigurations(Project project) { }); }; disableTransitiveDeps.accept(JavaPlugin.COMPILE_CONFIGURATION_NAME); - disableTransitiveDeps.accept(JavaPlugin.TEST_COMPILE_CONFIGURATION_NAME); disableTransitiveDeps.accept(JavaPlugin.COMPILE_ONLY_CONFIGURATION_NAME); disableTransitiveDeps.accept(JavaPlugin.RUNTIME_ONLY_CONFIGURATION_NAME); + disableTransitiveDeps.accept(JavaPlugin.TEST_IMPLEMENTATION_CONFIGURATION_NAME); } private static final Pattern LUCENE_SNAPSHOT_REGEX = Pattern.compile("\\w+-snapshot-([a-z0-9]+)"); diff --git a/buildSrc/src/main/java/org/elasticsearch/gradle/precommit/ThirdPartyAuditTask.java b/buildSrc/src/main/java/org/elasticsearch/gradle/precommit/ThirdPartyAuditTask.java index 578393014b795..6b70e31a3d068 100644 --- a/buildSrc/src/main/java/org/elasticsearch/gradle/precommit/ThirdPartyAuditTask.java +++ b/buildSrc/src/main/java/org/elasticsearch/gradle/precommit/ThirdPartyAuditTask.java @@ -391,7 +391,7 @@ private Set runJdkJarHellCheck() throws IOException { private Configuration getRuntimeConfiguration() { Configuration runtime = getProject().getConfigurations().findByName("runtimeClasspath"); if (runtime == null) { - return getProject().getConfigurations().getByName("testCompile"); + return getProject().getConfigurations().getByName("testCompileClasspath"); } return runtime; } diff --git a/buildSrc/src/testKit/testingConventions/build.gradle b/buildSrc/src/testKit/testingConventions/build.gradle index 877f98eed9d2d..2bb50da5a4ef5 100644 --- a/buildSrc/src/testKit/testingConventions/build.gradle +++ b/buildSrc/src/testKit/testingConventions/build.gradle @@ -10,7 +10,7 @@ allprojects { jcenter() } dependencies { - testCompile "junit:junit:4.12" + testImplementation "junit:junit:4.12" } ext.licenseFile = file("$buildDir/dummy/license") diff --git a/client/rest-high-level/build.gradle b/client/rest-high-level/build.gradle index a92a4f2342aa1..a74abca0aee8c 100644 --- a/client/rest-high-level/build.gradle +++ b/client/rest-high-level/build.gradle @@ -44,18 +44,19 @@ dependencies { compile project(':modules:rank-eval') compile project(':modules:lang-mustache') - testCompile project(':client:test') - testCompile project(':test:framework') - testCompile "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" - testCompile "junit:junit:${versions.junit}" + + testImplementation project(':client:test') + testImplementation project(':test:framework') + testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" + testImplementation "junit:junit:${versions.junit}" //this is needed to make RestHighLevelClientTests#testApiNamingConventions work from IDEs - testCompile project(":rest-api-spec") + testImplementation project(":rest-api-spec") // Needed for serialization tests: // (In order to serialize a server side class to a client side class or the other way around) - testCompile(project(':x-pack:plugin:core')) { + testImplementation(project(':x-pack:plugin:core')) { exclude group: 'org.elasticsearch', module: 'elasticsearch-rest-high-level-client' } - testCompile(project(':x-pack:plugin:eql')) + testImplementation(project(':x-pack:plugin:eql')) } processTestResources { diff --git a/client/rest/build.gradle b/client/rest/build.gradle index e11a9c5522d9b..2e52edc7c4c59 100644 --- a/client/rest/build.gradle +++ b/client/rest/build.gradle @@ -35,12 +35,12 @@ dependencies { compile "commons-codec:commons-codec:${versions.commonscodec}" compile "commons-logging:commons-logging:${versions.commonslogging}" - testCompile project(":client:test") - testCompile "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" - testCompile "junit:junit:${versions.junit}" - testCompile "org.hamcrest:hamcrest:${versions.hamcrest}" - testCompile "org.elasticsearch:securemock:${versions.securemock}" - testCompile "org.elasticsearch:mocksocket:${versions.mocksocket}" + testImplementation project(":client:test") + testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" + testImplementation "junit:junit:${versions.junit}" + testImplementation "org.hamcrest:hamcrest:${versions.hamcrest}" + testImplementation "org.elasticsearch:securemock:${versions.securemock}" + testImplementation "org.elasticsearch:mocksocket:${versions.mocksocket}" } tasks.withType(CheckForbiddenApis) { diff --git a/client/sniffer/build.gradle b/client/sniffer/build.gradle index 8f1b45e3af1e6..a5e6c64c90c40 100644 --- a/client/sniffer/build.gradle +++ b/client/sniffer/build.gradle @@ -33,11 +33,11 @@ dependencies { compile "commons-logging:commons-logging:${versions.commonslogging}" compile "com.fasterxml.jackson.core:jackson-core:${versions.jackson}" - testCompile project(":client:test") - testCompile "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" - testCompile "junit:junit:${versions.junit}" - testCompile "org.elasticsearch:securemock:${versions.securemock}" - testCompile "org.elasticsearch:mocksocket:${versions.mocksocket}" + testImplementation project(":client:test") + testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" + testImplementation "junit:junit:${versions.junit}" + testImplementation "org.elasticsearch:securemock:${versions.securemock}" + testImplementation "org.elasticsearch:mocksocket:${versions.mocksocket}" } forbiddenApisMain { diff --git a/client/transport/build.gradle b/client/transport/build.gradle index fe26293159d0d..aa3b80fa6a63e 100644 --- a/client/transport/build.gradle +++ b/client/transport/build.gradle @@ -29,9 +29,9 @@ dependencies { compile project(":modules:percolator") compile project(":modules:parent-join") compile project(":modules:rank-eval") - testCompile "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" - testCompile "junit:junit:${versions.junit}" - testCompile "org.hamcrest:hamcrest:${versions.hamcrest}" + testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" + testImplementation "junit:junit:${versions.junit}" + testImplementation "org.hamcrest:hamcrest:${versions.hamcrest}" } dependencyLicenses { diff --git a/distribution/tools/launchers/build.gradle b/distribution/tools/launchers/build.gradle index 4b1fdf668aec6..36e7be7c4dc87 100644 --- a/distribution/tools/launchers/build.gradle +++ b/distribution/tools/launchers/build.gradle @@ -22,9 +22,9 @@ apply plugin: 'elasticsearch.build' dependencies { compile parent.project('java-version-checker') - testCompile "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" - testCompile "junit:junit:${versions.junit}" - testCompile "org.hamcrest:hamcrest:${versions.hamcrest}" + testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" + testImplementation "junit:junit:${versions.junit}" + testImplementation "org.hamcrest:hamcrest:${versions.hamcrest}" } archivesBaseName = 'elasticsearch-launchers' diff --git a/distribution/tools/plugin-cli/build.gradle b/distribution/tools/plugin-cli/build.gradle index b6af1c18ac6ed..3c869188e29c5 100644 --- a/distribution/tools/plugin-cli/build.gradle +++ b/distribution/tools/plugin-cli/build.gradle @@ -28,9 +28,9 @@ dependencies { compileOnly project(":libs:elasticsearch-cli") compile "org.bouncycastle:bcpg-fips:1.0.3" compile "org.bouncycastle:bc-fips:1.0.1" - testCompile project(":test:framework") - testCompile 'com.google.jimfs:jimfs:1.1' - testCompile 'com.google.guava:guava:18.0' + testImplementation project(":test:framework") + testImplementation 'com.google.jimfs:jimfs:1.1' + testImplementation 'com.google.guava:guava:18.0' } dependencyLicenses { diff --git a/libs/core/build.gradle b/libs/core/build.gradle index 8915fb9894f69..243c5ab464808 100644 --- a/libs/core/build.gradle +++ b/libs/core/build.gradle @@ -67,15 +67,15 @@ dependencies { // This dependency is used only by :libs:core for null-checking interop with other tools compileOnly "com.google.code.findbugs:jsr305:3.0.2" - testCompile "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" - testCompile "junit:junit:${versions.junit}" - testCompile "org.hamcrest:hamcrest:${versions.hamcrest}" + testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" + testImplementation "junit:junit:${versions.junit}" + testImplementation "org.hamcrest:hamcrest:${versions.hamcrest}" if (!isEclipse) { java9Compile sourceSets.main.output } - testCompile(project(":test:framework")) { + testImplementation(project(":test:framework")) { exclude group: 'org.elasticsearch', module: 'elasticsearch-core' } } diff --git a/libs/dissect/build.gradle b/libs/dissect/build.gradle index f0791ea5a6981..19b54c0e742ec 100644 --- a/libs/dissect/build.gradle +++ b/libs/dissect/build.gradle @@ -18,12 +18,12 @@ */ dependencies { - testCompile(project(":test:framework")) { + testImplementation(project(":test:framework")) { exclude group: 'org.elasticsearch', module: 'elasticsearch-dissect' } - testCompile "com.fasterxml.jackson.core:jackson-core:${versions.jackson}" - testCompile "com.fasterxml.jackson.core:jackson-annotations:${versions.jackson}" - testCompile "com.fasterxml.jackson.core:jackson-databind:${versions.jackson}" + testImplementation "com.fasterxml.jackson.core:jackson-core:${versions.jackson}" + testImplementation "com.fasterxml.jackson.core:jackson-annotations:${versions.jackson}" + testImplementation "com.fasterxml.jackson.core:jackson-databind:${versions.jackson}" } forbiddenApisMain { diff --git a/libs/geo/build.gradle b/libs/geo/build.gradle index d989ecc0e3f54..bcedeba9ee28c 100644 --- a/libs/geo/build.gradle +++ b/libs/geo/build.gradle @@ -21,7 +21,7 @@ apply plugin: 'elasticsearch.build' apply plugin: 'elasticsearch.publish' dependencies { - testCompile(project(":test:framework")) { + testImplementation(project(":test:framework")) { exclude group: 'org.elasticsearch', module: 'elasticsearch-geo' } } diff --git a/libs/grok/build.gradle b/libs/grok/build.gradle index ba5811077ff4e..b39715ad3aee5 100644 --- a/libs/grok/build.gradle +++ b/libs/grok/build.gradle @@ -22,7 +22,7 @@ dependencies { // joni dependencies: compile 'org.jruby.jcodings:jcodings:1.0.44' - testCompile(project(":test:framework")) { + testImplementation(project(":test:framework")) { exclude group: 'org.elasticsearch', module: 'elasticsearch-grok' } } diff --git a/libs/nio/build.gradle b/libs/nio/build.gradle index c41ae1fdf4987..457ef397eee1b 100644 --- a/libs/nio/build.gradle +++ b/libs/nio/build.gradle @@ -21,11 +21,11 @@ apply plugin: 'elasticsearch.publish' dependencies { compile project(':libs:elasticsearch-core') - testCompile "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" - testCompile "junit:junit:${versions.junit}" - testCompile "org.hamcrest:hamcrest:${versions.hamcrest}" + testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" + testImplementation "junit:junit:${versions.junit}" + testImplementation "org.hamcrest:hamcrest:${versions.hamcrest}" - testCompile(project(":test:framework")) { + testImplementation(project(":test:framework")) { exclude group: 'org.elasticsearch', module: 'elasticsearch-nio' } } diff --git a/libs/secure-sm/build.gradle b/libs/secure-sm/build.gradle index ea8b4e4678f26..951aa67e5ab37 100644 --- a/libs/secure-sm/build.gradle +++ b/libs/secure-sm/build.gradle @@ -21,11 +21,11 @@ apply plugin: 'elasticsearch.publish' dependencies { // do not add non-test compile dependencies to secure-sm without a good reason to do so - testCompile "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" - testCompile "junit:junit:${versions.junit}" - testCompile "org.hamcrest:hamcrest:${versions.hamcrest}" + testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" + testImplementation "junit:junit:${versions.junit}" + testImplementation "org.hamcrest:hamcrest:${versions.hamcrest}" - testCompile(project(":test:framework")) { + testImplementation(project(":test:framework")) { exclude group: 'org.elasticsearch', module: 'elasticsearch-secure-sm' } } diff --git a/libs/ssl-config/build.gradle b/libs/ssl-config/build.gradle index dffe710754abc..189f7934db78a 100644 --- a/libs/ssl-config/build.gradle +++ b/libs/ssl-config/build.gradle @@ -21,13 +21,13 @@ apply plugin: "elasticsearch.publish" dependencies { compile project(':libs:elasticsearch-core') - testCompile(project(":test:framework")) { + testImplementation(project(":test:framework")) { exclude group: 'org.elasticsearch', module: 'elasticsearch-ssl-config' } - testCompile "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" - testCompile "junit:junit:${versions.junit}" - testCompile "org.hamcrest:hamcrest:${versions.hamcrest}" + testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" + testImplementation "junit:junit:${versions.junit}" + testImplementation "org.hamcrest:hamcrest:${versions.hamcrest}" } diff --git a/libs/x-content/build.gradle b/libs/x-content/build.gradle index 73d895f02128d..b3f1520872110 100644 --- a/libs/x-content/build.gradle +++ b/libs/x-content/build.gradle @@ -29,11 +29,11 @@ dependencies { compile "com.fasterxml.jackson.dataformat:jackson-dataformat-yaml:${versions.jackson}" compile "com.fasterxml.jackson.dataformat:jackson-dataformat-cbor:${versions.jackson}" - testCompile "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" - testCompile "junit:junit:${versions.junit}" - testCompile "org.hamcrest:hamcrest:${versions.hamcrest}" + testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" + testImplementation "junit:junit:${versions.junit}" + testImplementation "org.hamcrest:hamcrest:${versions.hamcrest}" - testCompile(project(":test:framework")) { + testImplementation(project(":test:framework")) { exclude group: 'org.elasticsearch', module: 'elasticsearch-x-content' } diff --git a/modules/ingest-geoip/build.gradle b/modules/ingest-geoip/build.gradle index 60df6626c1ef8..6dd15ea5718a0 100644 --- a/modules/ingest-geoip/build.gradle +++ b/modules/ingest-geoip/build.gradle @@ -31,7 +31,7 @@ dependencies { compile("com.fasterxml.jackson.core:jackson-databind:${versions.jackson}") compile('com.maxmind.db:maxmind-db:1.3.1') - testCompile 'org.elasticsearch:geolite2-databases:20191119' + testImplementation 'org.elasticsearch:geolite2-databases:20191119' } restResources { @@ -41,7 +41,7 @@ restResources { } task copyDefaultGeoIp2DatabaseFiles(type: Copy) { - from { zipTree(configurations.testCompile.files.find { it.name.contains('geolite2-databases') }) } + from { zipTree(configurations.testCompileClasspath.files.find { it.name.contains('geolite2-databases') }) } into "${project.buildDir}/ingest-geoip" include "*.mmdb" } diff --git a/modules/percolator/build.gradle b/modules/percolator/build.gradle index 7aec920d6b027..7b69e4c1bcc89 100644 --- a/modules/percolator/build.gradle +++ b/modules/percolator/build.gradle @@ -24,12 +24,12 @@ esplugin { } dependencies { - testCompile project(path: ':modules:parent-join', configuration: 'runtime') + testImplementation project(path: ':modules:parent-join', configuration: 'runtime') } restResources { restApi { - includeCore '_common', 'indices', 'index', 'search', 'msearch' + includeCore '_common', 'indices', 'index', 'search', 'msearch' } } dependencyLicenses { diff --git a/modules/reindex/build.gradle b/modules/reindex/build.gradle index c487ba1fa0831..bc5f77c4ed4c2 100644 --- a/modules/reindex/build.gradle +++ b/modules/reindex/build.gradle @@ -52,9 +52,9 @@ dependencies { compile project(":client:rest") compile project(":libs:elasticsearch-ssl-config") // for http - testing reindex from remote - testCompile project(path: ':modules:transport-netty4', configuration: 'runtime') + testImplementation project(path: ':modules:transport-netty4', configuration: 'runtime') // for parent/child testing - testCompile project(path: ':modules:parent-join', configuration: 'runtime') + testImplementation project(path: ':modules:parent-join', configuration: 'runtime') } restResources { diff --git a/plugins/discovery-ec2/qa/amazon-ec2/build.gradle b/plugins/discovery-ec2/qa/amazon-ec2/build.gradle index f2a940412d6d5..718f8d10edd2a 100644 --- a/plugins/discovery-ec2/qa/amazon-ec2/build.gradle +++ b/plugins/discovery-ec2/qa/amazon-ec2/build.gradle @@ -29,7 +29,7 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: ':plugins:discovery-ec2', configuration: 'runtime') + testImplementation project(path: ':plugins:discovery-ec2', configuration: 'runtime') } restResources { diff --git a/plugins/discovery-gce/qa/gce/build.gradle b/plugins/discovery-gce/qa/gce/build.gradle index 515530873df9f..515d6f2f160b2 100644 --- a/plugins/discovery-gce/qa/gce/build.gradle +++ b/plugins/discovery-gce/qa/gce/build.gradle @@ -30,7 +30,7 @@ apply plugin: 'elasticsearch.rest-test' final int gceNumberOfNodes = 3 dependencies { - testCompile project(path: ':plugins:discovery-gce', configuration: 'runtime') + testImplementation project(path: ':plugins:discovery-gce', configuration: 'runtime') } restResources { diff --git a/plugins/examples/security-authorization-engine/build.gradle b/plugins/examples/security-authorization-engine/build.gradle index 749cd49d6757d..abf631397e9d7 100644 --- a/plugins/examples/security-authorization-engine/build.gradle +++ b/plugins/examples/security-authorization-engine/build.gradle @@ -12,7 +12,7 @@ esplugin { dependencies { compileOnly "org.elasticsearch.plugin:x-pack-core:${versions.elasticsearch}" - testCompile "org.elasticsearch.client:x-pack-transport:${versions.elasticsearch}" + testImplementation "org.elasticsearch.client:x-pack-transport:${versions.elasticsearch}" } integTest { diff --git a/plugins/repository-azure/build.gradle b/plugins/repository-azure/build.gradle index 212eace636546..080fd90c1b2cd 100644 --- a/plugins/repository-azure/build.gradle +++ b/plugins/repository-azure/build.gradle @@ -33,7 +33,7 @@ dependencies { compile 'com.microsoft.azure:azure-keyvault-core:1.0.0' compile 'com.google.guava:guava:20.0' compile 'org.apache.commons:commons-lang3:3.4' - testCompile project(':test:fixtures:azure-fixture') + testImplementation project(':test:fixtures:azure-fixture') } restResources { diff --git a/plugins/repository-gcs/build.gradle b/plugins/repository-gcs/build.gradle index 5ceac5c62bd5f..7e0f50010158c 100644 --- a/plugins/repository-gcs/build.gradle +++ b/plugins/repository-gcs/build.gradle @@ -65,7 +65,7 @@ dependencies { compile 'io.opencensus:opencensus-contrib-http-util:0.18.0' compile 'com.google.apis:google-api-services-storage:v1-rev20191011-1.30.3' - testCompile project(':test:fixtures:gcs-fixture') + testImplementation project(':test:fixtures:gcs-fixture') } restResources { diff --git a/plugins/repository-s3/build.gradle b/plugins/repository-s3/build.gradle index 686864b25c0b9..743b09e476e94 100644 --- a/plugins/repository-s3/build.gradle +++ b/plugins/repository-s3/build.gradle @@ -50,7 +50,7 @@ dependencies { // and whitelist this hack in JarHell compile 'javax.xml.bind:jaxb-api:2.2.2' - testCompile project(':test:fixtures:s3-fixture') + testImplementation project(':test:fixtures:s3-fixture') } dependencyLicenses { diff --git a/qa/ccs-unavailable-clusters/build.gradle b/qa/ccs-unavailable-clusters/build.gradle index 0e04f87e99ffc..3bf98111944c2 100644 --- a/qa/ccs-unavailable-clusters/build.gradle +++ b/qa/ccs-unavailable-clusters/build.gradle @@ -22,5 +22,5 @@ apply plugin: 'elasticsearch.rest-test' apply plugin: 'elasticsearch.test-with-dependencies' dependencies { - testCompile project(":client:rest-high-level") + testImplementation project(":client:rest-high-level") } diff --git a/qa/evil-tests/build.gradle b/qa/evil-tests/build.gradle index c79832f4e99b5..5f3c5908d3706 100644 --- a/qa/evil-tests/build.gradle +++ b/qa/evil-tests/build.gradle @@ -27,7 +27,7 @@ apply plugin: 'elasticsearch.testclusters' apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile 'com.google.jimfs:jimfs:1.1' + testImplementation 'com.google.jimfs:jimfs:1.1' } // TODO: give each evil test its own fresh JVM for more isolation. diff --git a/qa/full-cluster-restart/build.gradle b/qa/full-cluster-restart/build.gradle index 02e7107758005..a441c295cb78f 100644 --- a/qa/full-cluster-restart/build.gradle +++ b/qa/full-cluster-restart/build.gradle @@ -75,6 +75,7 @@ for (Version bwcVersion : BuildParams.bwcVersions.indexCompatible) { configurations { testArtifacts.extendsFrom testRuntime + testArtifacts.extendsFrom testImplementation } task testJar(type: Jar) { diff --git a/qa/multi-cluster-search/build.gradle b/qa/multi-cluster-search/build.gradle index 125a341de6c11..85211e38a7849 100644 --- a/qa/multi-cluster-search/build.gradle +++ b/qa/multi-cluster-search/build.gradle @@ -23,7 +23,7 @@ apply plugin: 'elasticsearch.testclusters' apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(":client:rest-high-level") + testImplementation project(":client:rest-high-level") } task 'remote-cluster'(type: RestIntegTestTask) { diff --git a/qa/os/build.gradle b/qa/os/build.gradle index 476488430dc19..e31022db4b512 100644 --- a/qa/os/build.gradle +++ b/qa/os/build.gradle @@ -37,9 +37,9 @@ dependencies { compile project(':libs:elasticsearch-core') - testCompile "com.fasterxml.jackson.core:jackson-annotations:${versions.jackson}" - testCompile "com.fasterxml.jackson.core:jackson-core:${versions.jackson}" - testCompile "com.fasterxml.jackson.core:jackson-databind:${versions.jackson}" + testImplementation "com.fasterxml.jackson.core:jackson-annotations:${versions.jackson}" + testImplementation "com.fasterxml.jackson.core:jackson-core:${versions.jackson}" + testImplementation "com.fasterxml.jackson.core:jackson-databind:${versions.jackson}" } forbiddenApisTest { diff --git a/qa/remote-clusters/build.gradle b/qa/remote-clusters/build.gradle index 3be39e6a7be93..45796781bd476 100644 --- a/qa/remote-clusters/build.gradle +++ b/qa/remote-clusters/build.gradle @@ -28,7 +28,7 @@ apply plugin: 'elasticsearch.distribution-download' testFixtures.useFixture() dependencies { - testCompile project(':client:rest-high-level') + testImplementation project(':client:rest-high-level') } task copyKeystore(type: Sync) { diff --git a/qa/repository-multi-version/build.gradle b/qa/repository-multi-version/build.gradle index 40edc49169a5b..50bd71ad275b0 100644 --- a/qa/repository-multi-version/build.gradle +++ b/qa/repository-multi-version/build.gradle @@ -26,7 +26,7 @@ apply plugin: 'elasticsearch.standalone-test' apply from : "$rootDir/gradle/bwc-test.gradle" dependencies { - testCompile project(':client:rest-high-level') + testImplementation project(':client:rest-high-level') } for (Version bwcVersion : BuildParams.bwcVersions.indexCompatible) { @@ -89,6 +89,7 @@ for (Version bwcVersion : BuildParams.bwcVersions.indexCompatible) { configurations { testArtifacts.extendsFrom testRuntime + testArtifacts.extendsFrom testImplementation } task testJar(type: Jar) { diff --git a/qa/smoke-test-client/build.gradle b/qa/smoke-test-client/build.gradle index e5fc90b991577..230b6512109d4 100644 --- a/qa/smoke-test-client/build.gradle +++ b/qa/smoke-test-client/build.gradle @@ -25,7 +25,7 @@ apply plugin: 'elasticsearch.rest-test' // TODO: this test works, but it isn't really a rest test...should we have another plugin for "non rest test that just needs N clusters?" dependencies { - testCompile project(path: ':client:transport', configuration: 'runtime') // randomly swapped in as a transport + testImplementation project(path: ':client:transport', configuration: 'runtime') // randomly swapped in as a transport } task singleNodeIntegTest(type: RestIntegTestTask) { diff --git a/qa/smoke-test-http/build.gradle b/qa/smoke-test-http/build.gradle index 822c58e1bf457..0ed84740bf05e 100644 --- a/qa/smoke-test-http/build.gradle +++ b/qa/smoke-test-http/build.gradle @@ -23,8 +23,8 @@ apply plugin: 'elasticsearch.rest-test' apply plugin: 'elasticsearch.test-with-dependencies' dependencies { - testCompile project(path: ':modules:transport-netty4', configuration: 'runtime') // for http - testCompile project(path: ':plugins:transport-nio', configuration: 'runtime') // for http + testImplementation project(path: ':modules:transport-netty4', configuration: 'runtime') // for http + testImplementation project(path: ':plugins:transport-nio', configuration: 'runtime') // for http } integTest.runner { diff --git a/qa/smoke-test-ingest-disabled/build.gradle b/qa/smoke-test-ingest-disabled/build.gradle index 7a818d542a76f..dca3e705d78c7 100644 --- a/qa/smoke-test-ingest-disabled/build.gradle +++ b/qa/smoke-test-ingest-disabled/build.gradle @@ -22,7 +22,7 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: ':modules:ingest-common', configuration: 'runtime') + testImplementation project(path: ':modules:ingest-common', configuration: 'runtime') } testClusters.integTest { diff --git a/qa/smoke-test-ingest-with-all-dependencies/build.gradle b/qa/smoke-test-ingest-with-all-dependencies/build.gradle index 214a8597e6e14..c33eaba45720e 100644 --- a/qa/smoke-test-ingest-with-all-dependencies/build.gradle +++ b/qa/smoke-test-ingest-with-all-dependencies/build.gradle @@ -22,11 +22,11 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: ':modules:ingest-common', configuration: 'runtime') - testCompile project(path: ':modules:ingest-geoip', configuration: 'runtime') - testCompile project(path: ':modules:lang-mustache', configuration: 'runtime') - testCompile project(path: ':modules:lang-painless', configuration: 'runtime') - testCompile project(path: ':modules:reindex', configuration: 'runtime') + testImplementation project(path: ':modules:ingest-common', configuration: 'runtime') + testImplementation project(path: ':modules:ingest-geoip', configuration: 'runtime') + testImplementation project(path: ':modules:lang-mustache', configuration: 'runtime') + testImplementation project(path: ':modules:lang-painless', configuration: 'runtime') + testImplementation project(path: ':modules:reindex', configuration: 'runtime') } testingConventions { diff --git a/qa/wildfly/build.gradle b/qa/wildfly/build.gradle index 4b44a27cc3e81..b2f9ea2f81229 100644 --- a/qa/wildfly/build.gradle +++ b/qa/wildfly/build.gradle @@ -46,7 +46,7 @@ dependencies { compile "org.apache.logging.log4j:log4j-api:${versions.log4j}" compile "org.apache.logging.log4j:log4j-core:${versions.log4j}" compile project(path: ':client:rest-high-level') - testCompile project(':test:framework') + testImplementation project(':test:framework') } war { diff --git a/server/build.gradle b/server/build.gradle index 3c73839458f9c..6a62581860fe7 100644 --- a/server/build.gradle +++ b/server/build.gradle @@ -127,15 +127,15 @@ dependencies { java9Compile sourceSets.main.output } - testCompile(project(":test:framework")) { + testImplementation(project(":test:framework")) { // tests use the locally compiled version of server exclude group: 'org.elasticsearch', module: 'server' } - testCompile 'com.google.jimfs:jimfs:1.1' - testCompile 'com.google.guava:guava:18.0' + testImplementation 'com.google.jimfs:jimfs:1.1' + testImplementation 'com.google.guava:guava:18.0' - internalClusterTestCompile(project(":test:framework")) { + internalClusterTestImplementation(project(":test:framework")) { exclude group: 'org.elasticsearch', module: 'server' } } @@ -346,7 +346,6 @@ tasks.named('internalClusterTest').configure { systemProperty 'es.datastreams_feature_enabled', 'true' } } - licenseHeaders { excludes << 'org/elasticsearch/client/documentation/placeholder.txt' } diff --git a/test/logger-usage/build.gradle b/test/logger-usage/build.gradle index dc8db713d5953..38281b8527fe2 100644 --- a/test/logger-usage/build.gradle +++ b/test/logger-usage/build.gradle @@ -22,7 +22,7 @@ dependencies { compile 'org.ow2.asm:asm-tree:7.1' compile 'org.ow2.asm:asm-analysis:7.1' compile "org.apache.logging.log4j:log4j-api:${versions.log4j}" - testCompile project(":test:framework") + testImplementation project(":test:framework") } loggerUsageCheck.enabled = false diff --git a/x-pack/docs/build.gradle b/x-pack/docs/build.gradle index 9fa9f63af549c..d4f1f7f85d216 100644 --- a/x-pack/docs/build.gradle +++ b/x-pack/docs/build.gradle @@ -14,9 +14,9 @@ buildRestTests.expectedUnconvertedCandidates = [ ] dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackProject('plugin').path, configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackProject('plugin').path, configuration: 'testArtifacts') } restResources { diff --git a/x-pack/license-tools/build.gradle b/x-pack/license-tools/build.gradle index 2a032dc0cd15a..f0586be4b6de4 100644 --- a/x-pack/license-tools/build.gradle +++ b/x-pack/license-tools/build.gradle @@ -3,7 +3,7 @@ apply plugin: 'elasticsearch.build' dependencies { compile project(':x-pack:plugin:core') compile project(':server') - testCompile project(':test:framework') + testImplementation project(':test:framework') } project.forbiddenPatterns { diff --git a/x-pack/plugin/analytics/build.gradle b/x-pack/plugin/analytics/build.gradle index 889a3235bdeb7..754824ea09286 100644 --- a/x-pack/plugin/analytics/build.gradle +++ b/x-pack/plugin/analytics/build.gradle @@ -17,7 +17,7 @@ dependencies { compileOnly project(":server") compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } integTest.enabled = false diff --git a/x-pack/plugin/async-search/build.gradle b/x-pack/plugin/async-search/build.gradle index d357fcf9a6e10..4f5ed0b9c6706 100644 --- a/x-pack/plugin/async-search/build.gradle +++ b/x-pack/plugin/async-search/build.gradle @@ -26,8 +26,8 @@ dependencies { compileOnly project(":server") compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('ilm')) + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('ilm')) } dependencyLicenses { diff --git a/x-pack/plugin/async-search/qa/security/build.gradle b/x-pack/plugin/async-search/qa/security/build.gradle index 89ecc4617db18..0870fae96f854 100644 --- a/x-pack/plugin/async-search/qa/security/build.gradle +++ b/x-pack/plugin/async-search/qa/security/build.gradle @@ -3,9 +3,9 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('async-search'), configuration: 'runtime') - testCompile project(':x-pack:plugin:async-search:qa') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('async-search'), configuration: 'runtime') + testImplementation project(':x-pack:plugin:async-search:qa') } testClusters.integTest { diff --git a/x-pack/plugin/autoscaling/build.gradle b/x-pack/plugin/autoscaling/build.gradle index 709b988a2ab08..ed5b33461c258 100644 --- a/x-pack/plugin/autoscaling/build.gradle +++ b/x-pack/plugin/autoscaling/build.gradle @@ -16,7 +16,7 @@ integTest.enabled = false dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } // add all sub-projects of the qa sub-project diff --git a/x-pack/plugin/autoscaling/qa/rest/build.gradle b/x-pack/plugin/autoscaling/qa/rest/build.gradle index d7d66eeffc27f..b25ffe403de17 100644 --- a/x-pack/plugin/autoscaling/qa/rest/build.gradle +++ b/x-pack/plugin/autoscaling/qa/rest/build.gradle @@ -5,8 +5,8 @@ apply plugin: 'elasticsearch.testclusters' apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('autoscaling'), configuration: 'runtime') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('autoscaling'), configuration: 'runtime') } restResources { diff --git a/x-pack/plugin/build.gradle b/x-pack/plugin/build.gradle index e9f288c7c4710..def34881c6932 100644 --- a/x-pack/plugin/build.gradle +++ b/x-pack/plugin/build.gradle @@ -12,8 +12,8 @@ apply plugin: 'elasticsearch.validate-rest-spec' archivesBaseName = 'x-pack' dependencies { - testCompile project(xpackModule('core')) // this redundant dependency is here to make IntelliJ happy - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(xpackModule('core')) // this redundant dependency is here to make IntelliJ happy + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } subprojects { @@ -67,6 +67,7 @@ subprojects { configurations { testArtifacts.extendsFrom testRuntime + testArtifacts.extendsFrom testImplementation } artifacts { diff --git a/x-pack/plugin/ccr/build.gradle b/x-pack/plugin/ccr/build.gradle index 23c8260cc24ef..bd4e968ebde92 100644 --- a/x-pack/plugin/ccr/build.gradle +++ b/x-pack/plugin/ccr/build.gradle @@ -42,8 +42,8 @@ dependencies { compileOnly project(":server") compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('monitoring'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('monitoring'), configuration: 'testArtifacts') } dependencyLicenses { diff --git a/x-pack/plugin/ccr/qa/downgrade-to-basic-license/build.gradle b/x-pack/plugin/ccr/qa/downgrade-to-basic-license/build.gradle index 6a7162fae4deb..17d463a90a287 100644 --- a/x-pack/plugin/ccr/qa/downgrade-to-basic-license/build.gradle +++ b/x-pack/plugin/ccr/qa/downgrade-to-basic-license/build.gradle @@ -4,9 +4,9 @@ apply plugin: 'elasticsearch.testclusters' apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('ccr'), configuration: 'runtime') - testCompile project(':x-pack:plugin:ccr:qa') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('ccr'), configuration: 'runtime') + testImplementation project(':x-pack:plugin:ccr:qa') } task "leader-cluster"(type: RestIntegTestTask) { diff --git a/x-pack/plugin/ccr/qa/multi-cluster/build.gradle b/x-pack/plugin/ccr/qa/multi-cluster/build.gradle index 050d696872ad4..1f1849759f3d9 100644 --- a/x-pack/plugin/ccr/qa/multi-cluster/build.gradle +++ b/x-pack/plugin/ccr/qa/multi-cluster/build.gradle @@ -4,9 +4,9 @@ apply plugin: 'elasticsearch.testclusters' apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('ccr'), configuration: 'runtime') - testCompile project(':x-pack:plugin:ccr:qa') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('ccr'), configuration: 'runtime') + testImplementation project(':x-pack:plugin:ccr:qa') } task "leader-cluster"(type: RestIntegTestTask) { diff --git a/x-pack/plugin/ccr/qa/non-compliant-license/build.gradle b/x-pack/plugin/ccr/qa/non-compliant-license/build.gradle index 40e71a601994c..51fdcbec4bab5 100644 --- a/x-pack/plugin/ccr/qa/non-compliant-license/build.gradle +++ b/x-pack/plugin/ccr/qa/non-compliant-license/build.gradle @@ -4,9 +4,9 @@ apply plugin: 'elasticsearch.testclusters' apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('ccr'), configuration: 'runtime') - testCompile project(':x-pack:plugin:ccr:qa:') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('ccr'), configuration: 'runtime') + testImplementation project(':x-pack:plugin:ccr:qa:') } task 'leader-cluster'(type: RestIntegTestTask) { diff --git a/x-pack/plugin/ccr/qa/rest/build.gradle b/x-pack/plugin/ccr/qa/rest/build.gradle index fd16660178c57..4397484b9973e 100644 --- a/x-pack/plugin/ccr/qa/rest/build.gradle +++ b/x-pack/plugin/ccr/qa/rest/build.gradle @@ -11,8 +11,8 @@ restResources { } dependencies { - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('ccr'), configuration: 'runtime') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('ccr'), configuration: 'runtime') } task restTest(type: RestIntegTestTask) { diff --git a/x-pack/plugin/ccr/qa/restart/build.gradle b/x-pack/plugin/ccr/qa/restart/build.gradle index 5b2078be53786..b2edb5e32d337 100644 --- a/x-pack/plugin/ccr/qa/restart/build.gradle +++ b/x-pack/plugin/ccr/qa/restart/build.gradle @@ -5,7 +5,7 @@ apply plugin: 'elasticsearch.testclusters' apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(':x-pack:plugin:ccr:qa') + testImplementation project(':x-pack:plugin:ccr:qa') } task 'leader-cluster'(type: RestIntegTestTask) { diff --git a/x-pack/plugin/ccr/qa/security/build.gradle b/x-pack/plugin/ccr/qa/security/build.gradle index 64e831876026d..b629f4cd9901e 100644 --- a/x-pack/plugin/ccr/qa/security/build.gradle +++ b/x-pack/plugin/ccr/qa/security/build.gradle @@ -4,9 +4,9 @@ apply plugin: 'elasticsearch.testclusters' apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('ccr'), configuration: 'runtime') - testCompile project(':x-pack:plugin:ccr:qa') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('ccr'), configuration: 'runtime') + testImplementation project(':x-pack:plugin:ccr:qa') } task 'leader-cluster'(type: RestIntegTestTask) { diff --git a/x-pack/plugin/core/build.gradle b/x-pack/plugin/core/build.gradle index 719e319b5b6ea..5d1700838621e 100644 --- a/x-pack/plugin/core/build.gradle +++ b/x-pack/plugin/core/build.gradle @@ -43,16 +43,16 @@ dependencies { exclude group: "org.elasticsearch", module: "elasticsearch-core" } - testCompile 'org.elasticsearch:securemock:1.2' - testCompile "org.elasticsearch:mocksocket:${versions.mocksocket}" - testCompile "org.apache.logging.log4j:log4j-slf4j-impl:${versions.log4j}" - testCompile "org.slf4j:slf4j-api:${versions.slf4j}" - testCompile project(path: ':modules:reindex', configuration: 'runtime') - testCompile project(path: ':modules:parent-join', configuration: 'runtime') - testCompile project(path: ':modules:lang-mustache', configuration: 'runtime') - testCompile project(path: ':modules:analysis-common', configuration: 'runtime') - testCompile project(':client:rest-high-level') - testCompile(project(':x-pack:license-tools')) { + testImplementation 'org.elasticsearch:securemock:1.2' + testImplementation "org.elasticsearch:mocksocket:${versions.mocksocket}" + testImplementation "org.apache.logging.log4j:log4j-slf4j-impl:${versions.log4j}" + testImplementation "org.slf4j:slf4j-api:${versions.slf4j}" + testImplementation project(path: ':modules:reindex', configuration: 'runtime') + testImplementation project(path: ':modules:parent-join', configuration: 'runtime') + testImplementation project(path: ':modules:lang-mustache', configuration: 'runtime') + testImplementation project(path: ':modules:analysis-common', configuration: 'runtime') + testImplementation project(':client:rest-high-level') + testImplementation(project(':x-pack:license-tools')) { transitive = false } @@ -115,6 +115,7 @@ test { // https://github.com/elastic/x-plugins/issues/724 configurations { testArtifacts.extendsFrom testRuntime + testArtifacts.extendsFrom testImplementation } task testJar(type: Jar) { appendix 'test' @@ -141,4 +142,3 @@ thirdPartyAudit.ignoreMissingClasses( // installing them as individual plugins for integ tests doesn't make sense, // so we disable integ tests integTest.enabled = false - diff --git a/x-pack/plugin/enrich/build.gradle b/x-pack/plugin/enrich/build.gradle index e7206f336aec6..76064dd4555b1 100644 --- a/x-pack/plugin/enrich/build.gradle +++ b/x-pack/plugin/enrich/build.gradle @@ -12,10 +12,10 @@ archivesBaseName = 'x-pack-enrich' dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: ':modules:ingest-common') - testCompile project(path: ':modules:lang-mustache') - testCompile project(path: xpackModule('monitoring'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: ':modules:ingest-common') + testImplementation project(path: ':modules:lang-mustache') + testImplementation project(path: xpackModule('monitoring'), configuration: 'testArtifacts') } // No real integ tests in the module: diff --git a/x-pack/plugin/enrich/qa/rest-with-security/build.gradle b/x-pack/plugin/enrich/qa/rest-with-security/build.gradle index b9b90064c13eb..2bcc86b95a5f7 100644 --- a/x-pack/plugin/enrich/qa/rest-with-security/build.gradle +++ b/x-pack/plugin/enrich/qa/rest-with-security/build.gradle @@ -3,9 +3,9 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('enrich'), configuration: 'runtime') - testCompile project(path: xpackModule('core'), configuration: 'runtime') - testCompile project(path: xpackModule('enrich:qa:common'), configuration: 'runtime') + testImplementation project(path: xpackModule('enrich'), configuration: 'runtime') + testImplementation project(path: xpackModule('core'), configuration: 'runtime') + testImplementation project(path: xpackModule('enrich:qa:common'), configuration: 'runtime') } testClusters.integTest { diff --git a/x-pack/plugin/enrich/qa/rest/build.gradle b/x-pack/plugin/enrich/qa/rest/build.gradle index 9344134741778..6cf561519c87f 100644 --- a/x-pack/plugin/enrich/qa/rest/build.gradle +++ b/x-pack/plugin/enrich/qa/rest/build.gradle @@ -10,8 +10,8 @@ restResources { } dependencies { - testCompile project(path: xpackModule('enrich'), configuration: 'runtime') - testCompile project(path: xpackModule('enrich:qa:common'), configuration: 'runtime') + testImplementation project(path: xpackModule('enrich'), configuration: 'runtime') + testImplementation project(path: xpackModule('enrich:qa:common'), configuration: 'runtime') } testClusters.integTest { diff --git a/x-pack/plugin/eql/build.gradle b/x-pack/plugin/eql/build.gradle index 13b12a0d88799..137d3fecd02d8 100644 --- a/x-pack/plugin/eql/build.gradle +++ b/x-pack/plugin/eql/build.gradle @@ -27,13 +27,13 @@ dependencies { } compile "org.antlr:antlr4-runtime:${antlrVersion}" compileOnly project(path: xpackModule('ql'), configuration: 'default') - testCompile project(':test:framework') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('ql'), configuration: 'testArtifacts') - testCompile project(path: ':modules:reindex', configuration: 'runtime') - testCompile project(path: ':modules:parent-join', configuration: 'runtime') - testCompile project(path: ':modules:analysis-common', configuration: 'runtime') + testImplementation project(':test:framework') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('ql'), configuration: 'testArtifacts') + testImplementation project(path: ':modules:reindex', configuration: 'runtime') + testImplementation project(path: ':modules:parent-join', configuration: 'runtime') + testImplementation project(path: ':modules:analysis-common', configuration: 'runtime') } diff --git a/x-pack/plugin/eql/qa/rest/build.gradle b/x-pack/plugin/eql/qa/rest/build.gradle index 43077d1d5c5d8..efa7e712dbe0e 100644 --- a/x-pack/plugin/eql/qa/rest/build.gradle +++ b/x-pack/plugin/eql/qa/rest/build.gradle @@ -12,8 +12,8 @@ restResources { } dependencies { - testCompile project(path: xpackModule('eql'), configuration: 'runtime') - testCompile project(path: xpackModule('eql:qa:common'), configuration: 'runtime') + testImplementation project(path: xpackModule('eql'), configuration: 'runtime') + testImplementation project(path: xpackModule('eql:qa:common'), configuration: 'runtime') } testClusters.integTest { diff --git a/x-pack/plugin/frozen-indices/build.gradle b/x-pack/plugin/frozen-indices/build.gradle index 4f298887a35ea..f69e88fcd42ea 100644 --- a/x-pack/plugin/frozen-indices/build.gradle +++ b/x-pack/plugin/frozen-indices/build.gradle @@ -11,7 +11,7 @@ archivesBaseName = 'x-pack-frozen-indices' dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } // xpack modules are installed in real clusters as the meta plugin, so diff --git a/x-pack/plugin/graph/build.gradle b/x-pack/plugin/graph/build.gradle index 8a46d5a57214b..e8174edb162a6 100644 --- a/x-pack/plugin/graph/build.gradle +++ b/x-pack/plugin/graph/build.gradle @@ -11,7 +11,7 @@ archivesBaseName = 'x-pack-graph' dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } // add all sub-projects of the qa sub-project diff --git a/x-pack/plugin/graph/qa/with-security/build.gradle b/x-pack/plugin/graph/qa/with-security/build.gradle index 2f0461dd3f189..3d5891d113957 100644 --- a/x-pack/plugin/graph/qa/with-security/build.gradle +++ b/x-pack/plugin/graph/qa/with-security/build.gradle @@ -3,7 +3,7 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(":x-pack:plugin:core") + testImplementation project(":x-pack:plugin:core") } // bring in graph rest test suite diff --git a/x-pack/plugin/identity-provider/build.gradle b/x-pack/plugin/identity-provider/build.gradle index 340920323b90f..6e39c2fc3e6bc 100644 --- a/x-pack/plugin/identity-provider/build.gradle +++ b/x-pack/plugin/identity-provider/build.gradle @@ -15,9 +15,9 @@ archivesBaseName = 'x-pack-identity-provider' dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') // So that we can extend LocalStateCompositeXPackPlugin - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') // the following are all SAML dependencies - might as well download the whole internet compile "org.opensaml:opensaml-core:3.4.5" @@ -50,8 +50,8 @@ dependencies { compile "org.apache.httpcomponents:httpclient-cache:${versions.httpclient}" compile 'com.google.guava:guava:19.0' - testCompile 'org.elasticsearch:securemock:1.2' - testCompile "org.elasticsearch:mocksocket:${versions.mocksocket}" + testImplementation 'org.elasticsearch:securemock:1.2' + testImplementation "org.elasticsearch:mocksocket:${versions.mocksocket}" } compileJava.options.compilerArgs << "-Xlint:-rawtypes,-unchecked" diff --git a/x-pack/plugin/identity-provider/qa/idp-rest-tests/build.gradle b/x-pack/plugin/identity-provider/qa/idp-rest-tests/build.gradle index b7cc138f99b4b..70d1a8b3aeea5 100644 --- a/x-pack/plugin/identity-provider/qa/idp-rest-tests/build.gradle +++ b/x-pack/plugin/identity-provider/qa/idp-rest-tests/build.gradle @@ -3,9 +3,9 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('identity-provider'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('identity-provider'), configuration: 'default') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } testClusters.integTest { diff --git a/x-pack/plugin/ilm/build.gradle b/x-pack/plugin/ilm/build.gradle index 9d6e18fca026b..52839f2db2f86 100644 --- a/x-pack/plugin/ilm/build.gradle +++ b/x-pack/plugin/ilm/build.gradle @@ -14,7 +14,7 @@ archivesBaseName = 'x-pack-ilm' dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } // add all sub-projects of the qa sub-project diff --git a/x-pack/plugin/ilm/qa/multi-cluster/build.gradle b/x-pack/plugin/ilm/qa/multi-cluster/build.gradle index d8c5a82561485..a1201c647c0f5 100644 --- a/x-pack/plugin/ilm/qa/multi-cluster/build.gradle +++ b/x-pack/plugin/ilm/qa/multi-cluster/build.gradle @@ -4,9 +4,9 @@ apply plugin: 'elasticsearch.testclusters' apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(':x-pack:plugin:ccr:qa') - testCompile project(':x-pack:plugin:core') - testCompile project(':x-pack:plugin:ilm') + testImplementation project(':x-pack:plugin:ccr:qa') + testImplementation project(':x-pack:plugin:core') + testImplementation project(':x-pack:plugin:ilm') } File repoDir = file("$buildDir/testclusters/repo") diff --git a/x-pack/plugin/ilm/qa/multi-node/build.gradle b/x-pack/plugin/ilm/qa/multi-node/build.gradle index bb0c247b5c85e..933f6d69043df 100644 --- a/x-pack/plugin/ilm/qa/multi-node/build.gradle +++ b/x-pack/plugin/ilm/qa/multi-node/build.gradle @@ -5,7 +5,7 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackProject('plugin').path, configuration: 'testArtifacts') + testImplementation project(path: xpackProject('plugin').path, configuration: 'testArtifacts') } File repoDir = file("$buildDir/testclusters/repo") diff --git a/x-pack/plugin/ilm/qa/rest/build.gradle b/x-pack/plugin/ilm/qa/rest/build.gradle index c217af251ee55..d941ff42b46c9 100644 --- a/x-pack/plugin/ilm/qa/rest/build.gradle +++ b/x-pack/plugin/ilm/qa/rest/build.gradle @@ -4,8 +4,8 @@ apply plugin: 'elasticsearch.testclusters' apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('ilm'), configuration: 'runtime') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('ilm'), configuration: 'runtime') } restResources { diff --git a/x-pack/plugin/ilm/qa/with-security/build.gradle b/x-pack/plugin/ilm/qa/with-security/build.gradle index 6882ad98b4335..48ca07e68427f 100644 --- a/x-pack/plugin/ilm/qa/with-security/build.gradle +++ b/x-pack/plugin/ilm/qa/with-security/build.gradle @@ -3,8 +3,8 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackProject('plugin').path, configuration: 'testArtifacts') - testCompile project(":client:rest-high-level") + testImplementation project(path: xpackProject('plugin').path, configuration: 'testArtifacts') + testImplementation project(":client:rest-high-level") } def clusterCredentials = [username: System.getProperty('tests.rest.cluster.username', 'test_admin'), diff --git a/x-pack/plugin/logstash/build.gradle b/x-pack/plugin/logstash/build.gradle index ae3f04321e0ed..96d38165554be 100644 --- a/x-pack/plugin/logstash/build.gradle +++ b/x-pack/plugin/logstash/build.gradle @@ -11,7 +11,7 @@ archivesBaseName = 'x-pack-logstash' dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } integTest.enabled = false diff --git a/x-pack/plugin/mapper-constant-keyword/build.gradle b/x-pack/plugin/mapper-constant-keyword/build.gradle index ba4e0d1b2a757..f23ce5a467dec 100644 --- a/x-pack/plugin/mapper-constant-keyword/build.gradle +++ b/x-pack/plugin/mapper-constant-keyword/build.gradle @@ -18,7 +18,7 @@ archivesBaseName = 'x-pack-constant-keyword' dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } integTest.enabled = false diff --git a/x-pack/plugin/mapper-flattened/build.gradle b/x-pack/plugin/mapper-flattened/build.gradle index 979da98fdc0a4..e117ca70839ef 100644 --- a/x-pack/plugin/mapper-flattened/build.gradle +++ b/x-pack/plugin/mapper-flattened/build.gradle @@ -18,7 +18,7 @@ archivesBaseName = 'x-pack-flattened' dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } integTest.enabled = false diff --git a/x-pack/plugin/ml/build.gradle b/x-pack/plugin/ml/build.gradle index 20613721219dc..84335ece7b520 100644 --- a/x-pack/plugin/ml/build.gradle +++ b/x-pack/plugin/ml/build.gradle @@ -50,10 +50,10 @@ bundlePlugin { dependencies { compileOnly project(':modules:lang-painless:spi') compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('ilm'), configuration: 'default') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('ilm'), configuration: 'default') // This should not be here - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') // ml deps compile project(':libs:elasticsearch-grok') @@ -62,11 +62,12 @@ dependencies { nativeBundle("org.elasticsearch.ml:ml-cpp:${project.version}@zip") { changing = true } - testCompile 'org.ini4j:ini4j:0.5.2' + testImplementation 'org.ini4j:ini4j:0.5.2' } configurations { testArtifacts.extendsFrom testRuntime + testArtifacts.extendsFrom testImplementation } task testJar(type: Jar) { appendix 'test' diff --git a/x-pack/plugin/ml/qa/basic-multi-node/build.gradle b/x-pack/plugin/ml/qa/basic-multi-node/build.gradle index 85230609743cc..ef3533a82bb39 100644 --- a/x-pack/plugin/ml/qa/basic-multi-node/build.gradle +++ b/x-pack/plugin/ml/qa/basic-multi-node/build.gradle @@ -3,8 +3,8 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(":x-pack:plugin:core") - testCompile project(path: xpackModule('ml'), configuration: 'runtime') + testImplementation project(":x-pack:plugin:core") + testImplementation project(path: xpackModule('ml'), configuration: 'runtime') } testClusters.integTest { diff --git a/x-pack/plugin/ml/qa/disabled/build.gradle b/x-pack/plugin/ml/qa/disabled/build.gradle index 3ffaee2256b1e..98d124f97344a 100644 --- a/x-pack/plugin/ml/qa/disabled/build.gradle +++ b/x-pack/plugin/ml/qa/disabled/build.gradle @@ -3,8 +3,8 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(":x-pack:plugin:core") - testCompile project(path: xpackModule('ml'), configuration: 'runtime') + testImplementation project(":x-pack:plugin:core") + testImplementation project(path: xpackModule('ml'), configuration: 'runtime') } testClusters.integTest { diff --git a/x-pack/plugin/ml/qa/ml-with-security/build.gradle b/x-pack/plugin/ml/qa/ml-with-security/build.gradle index 1863bb096ee00..7f32019954ce5 100644 --- a/x-pack/plugin/ml/qa/ml-with-security/build.gradle +++ b/x-pack/plugin/ml/qa/ml-with-security/build.gradle @@ -3,9 +3,9 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackProject('plugin').path, configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackProject('plugin').path, configuration: 'testArtifacts') } // bring in machine learning rest test suite diff --git a/x-pack/plugin/ml/qa/native-multi-node-tests/build.gradle b/x-pack/plugin/ml/qa/native-multi-node-tests/build.gradle index 419f5d129a619..5acff962ef576 100644 --- a/x-pack/plugin/ml/qa/native-multi-node-tests/build.gradle +++ b/x-pack/plugin/ml/qa/native-multi-node-tests/build.gradle @@ -3,10 +3,10 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('ml'), configuration: 'runtime') - testCompile project(path: xpackModule('ml'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('ml'), configuration: 'runtime') + testImplementation project(path: xpackModule('ml'), configuration: 'testArtifacts') } // location for keys and certificates diff --git a/x-pack/plugin/ml/qa/no-bootstrap-tests/build.gradle b/x-pack/plugin/ml/qa/no-bootstrap-tests/build.gradle index 4dec75107271a..a2ca102829dbf 100644 --- a/x-pack/plugin/ml/qa/no-bootstrap-tests/build.gradle +++ b/x-pack/plugin/ml/qa/no-bootstrap-tests/build.gradle @@ -1,6 +1,6 @@ apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(":x-pack:plugin:core") - testCompile project(path: xpackModule('ml'), configuration: 'runtime') + testImplementation project(":x-pack:plugin:core") + testImplementation project(path: xpackModule('ml'), configuration: 'runtime') } diff --git a/x-pack/plugin/ml/qa/single-node-tests/build.gradle b/x-pack/plugin/ml/qa/single-node-tests/build.gradle index c5f14a71f39df..a1c0ea5b94e6d 100644 --- a/x-pack/plugin/ml/qa/single-node-tests/build.gradle +++ b/x-pack/plugin/ml/qa/single-node-tests/build.gradle @@ -3,8 +3,8 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(":x-pack:plugin:core") - testCompile project(path: xpackModule('ml'), configuration: 'runtime') + testImplementation project(":x-pack:plugin:core") + testImplementation project(path: xpackModule('ml'), configuration: 'runtime') } testClusters.integTest { diff --git a/x-pack/plugin/monitoring/build.gradle b/x-pack/plugin/monitoring/build.gradle index 751a5ed07836c..40a6adba49b88 100644 --- a/x-pack/plugin/monitoring/build.gradle +++ b/x-pack/plugin/monitoring/build.gradle @@ -12,16 +12,16 @@ archivesBaseName = 'x-pack-monitoring' dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') // monitoring deps compile project(':client:rest') compile project(':client:sniffer') // baz - this goes away after we separate out the actions #27759 - testCompile project(xpackModule('watcher')) + testImplementation project(xpackModule('watcher')) - testCompile project(xpackModule('ilm')) + testImplementation project(xpackModule('ilm')) } compileJava.options.compilerArgs << "-Xlint:-rawtypes,-unchecked" @@ -30,6 +30,7 @@ compileInternalClusterTestJava.options.compilerArgs << "-Xlint:-rawtypes" configurations { testArtifacts.extendsFrom testRuntime + testArtifacts.extendsFrom testImplementation } task testJar(type: Jar) { appendix 'test' diff --git a/x-pack/plugin/ql/build.gradle b/x-pack/plugin/ql/build.gradle index c74b8a8bcb4a3..daab9a2716d9b 100644 --- a/x-pack/plugin/ql/build.gradle +++ b/x-pack/plugin/ql/build.gradle @@ -12,12 +12,13 @@ archivesBaseName = 'x-pack-ql' dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(':test:framework') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(':test:framework') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } configurations { testArtifacts.extendsFrom testRuntime + testArtifacts.extendsFrom testImplementation } task testJar(type: Jar) { diff --git a/x-pack/plugin/rollup/build.gradle b/x-pack/plugin/rollup/build.gradle index 96f679ac30aa7..209326ffb1c57 100644 --- a/x-pack/plugin/rollup/build.gradle +++ b/x-pack/plugin/rollup/build.gradle @@ -17,7 +17,7 @@ dependencies { compileOnly project(":server") compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } integTest.enabled = false diff --git a/x-pack/plugin/search-business-rules/build.gradle b/x-pack/plugin/search-business-rules/build.gradle index 40919bf4334cd..401c4e6396599 100644 --- a/x-pack/plugin/search-business-rules/build.gradle +++ b/x-pack/plugin/search-business-rules/build.gradle @@ -16,8 +16,8 @@ integTest.enabled = false dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(":test:framework") + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(":test:framework") } // copied from CCR diff --git a/x-pack/plugin/security/build.gradle b/x-pack/plugin/security/build.gradle index b95cc31b50cb5..6dd9a6c3e5a09 100644 --- a/x-pack/plugin/security/build.gradle +++ b/x-pack/plugin/security/build.gradle @@ -19,12 +19,12 @@ dependencies { compileOnly project(path: ':modules:transport-netty4', configuration: 'runtime') compileOnly project(path: ':plugins:transport-nio', configuration: 'runtime') - testCompile project(path: xpackModule('monitoring')) - testCompile project(path: xpackModule('sql:sql-action')) + testImplementation project(path: xpackModule('monitoring')) + testImplementation project(path: xpackModule('sql:sql-action')) - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') - compile 'com.unboundid:unboundid-ldapsdk:4.0.8' + compile 'com.unboundid:unboundid-ldapsdk:4.0.8' // the following are all SAML dependencies - might as well download the whole internet compile "org.opensaml:opensaml-core:3.4.5" @@ -45,7 +45,7 @@ dependencies { compile "net.shibboleth.utilities:java-support:7.5.1" compile "org.apache.santuario:xmlsec:2.1.4" compile "io.dropwizard.metrics:metrics-core:3.2.2" - compile ("org.cryptacular:cryptacular:1.2.4") { + compile("org.cryptacular:cryptacular:1.2.4") { exclude group: 'org.bouncycastle' } compile "org.slf4j:slf4j-api:${versions.slf4j}" @@ -67,71 +67,70 @@ dependencies { compile "net.minidev:accessors-smart:1.2" compile "org.ow2.asm:asm:7.1" - testCompile 'org.elasticsearch:securemock:1.2' - testCompile "org.elasticsearch:mocksocket:${versions.mocksocket}" - //testCompile "org.yaml:snakeyaml:${versions.snakeyaml}" + testImplementation 'org.elasticsearch:securemock:1.2' + testImplementation "org.elasticsearch:mocksocket:${versions.mocksocket}" // Test dependencies for Kerberos (MiniKdc) - testCompile('commons-io:commons-io:2.5') - testCompile('org.apache.kerby:kerb-simplekdc:1.1.1') - testCompile('org.apache.kerby:kerb-client:1.1.1') - testCompile('org.apache.kerby:kerby-config:1.1.1') - testCompile('org.apache.kerby:kerb-core:1.1.1') - testCompile('org.apache.kerby:kerby-pkix:1.1.1') - testCompile('org.apache.kerby:kerby-asn1:1.1.1') - testCompile('org.apache.kerby:kerby-util:1.1.1') - testCompile('org.apache.kerby:kerb-common:1.1.1') - testCompile('org.apache.kerby:kerb-crypto:1.1.1') - testCompile('org.apache.kerby:kerb-util:1.1.1') - testCompile('org.apache.kerby:token-provider:1.1.1') - testCompile('com.nimbusds:nimbus-jose-jwt:8.6') - testCompile('net.jcip:jcip-annotations:1.0') - testCompile('org.apache.kerby:kerb-admin:1.1.1') - testCompile('org.apache.kerby:kerb-server:1.1.1') - testCompile('org.apache.kerby:kerb-identity:1.1.1') - testCompile('org.apache.kerby:kerby-xdr:1.1.1') + testImplementation('commons-io:commons-io:2.5') + testImplementation('org.apache.kerby:kerb-simplekdc:1.1.1') + testImplementation('org.apache.kerby:kerb-client:1.1.1') + testImplementation('org.apache.kerby:kerby-config:1.1.1') + testImplementation('org.apache.kerby:kerb-core:1.1.1') + testImplementation('org.apache.kerby:kerby-pkix:1.1.1') + testImplementation('org.apache.kerby:kerby-asn1:1.1.1') + testImplementation('org.apache.kerby:kerby-util:1.1.1') + testImplementation('org.apache.kerby:kerb-common:1.1.1') + testImplementation('org.apache.kerby:kerb-crypto:1.1.1') + testImplementation('org.apache.kerby:kerb-util:1.1.1') + testImplementation('org.apache.kerby:token-provider:1.1.1') + testImplementation('com.nimbusds:nimbus-jose-jwt:8.6') + testImplementation('net.jcip:jcip-annotations:1.0') + testImplementation('org.apache.kerby:kerb-admin:1.1.1') + testImplementation('org.apache.kerby:kerb-server:1.1.1') + testImplementation('org.apache.kerby:kerb-identity:1.1.1') + testImplementation('org.apache.kerby:kerby-xdr:1.1.1') // LDAP backend support for SimpleKdcServer - testCompile('org.apache.kerby:kerby-backend:1.1.1') - testCompile('org.apache.kerby:ldap-backend:1.1.1') - testCompile('org.apache.kerby:kerb-identity:1.1.1') - testCompile('org.apache.directory.api:api-ldap-client-api:1.0.0') - testCompile('org.apache.directory.api:api-ldap-schema-data:1.0.0') - testCompile('org.apache.directory.api:api-ldap-codec-core:1.0.0') - testCompile('org.apache.directory.api:api-ldap-extras-aci:1.0.0') - testCompile('org.apache.directory.api:api-ldap-extras-codec:1.0.0') - testCompile('org.apache.directory.api:api-ldap-extras-codec-api:1.0.0') - testCompile('commons-pool:commons-pool:1.6') - testCompile('commons-collections:commons-collections:3.2.2') - testCompile('org.apache.mina:mina-core:2.0.17') - testCompile('org.apache.directory.api:api-util:1.0.1') - testCompile('org.apache.directory.api:api-i18n:1.0.1') - testCompile('org.apache.directory.api:api-ldap-model:1.0.1') - testCompile('org.apache.directory.api:api-asn1-api:1.0.1') - testCompile('org.apache.directory.api:api-asn1-ber:1.0.1') - testCompile('org.apache.servicemix.bundles:org.apache.servicemix.bundles.antlr:2.7.7_5') - testCompile('org.apache.directory.server:apacheds-core-api:2.0.0-M24') - testCompile('org.apache.directory.server:apacheds-i18n:2.0.0-M24') - testCompile('org.apache.directory.api:api-ldap-extras-util:1.0.0') - testCompile('net.sf.ehcache:ehcache:2.10.4') - testCompile('org.apache.directory.server:apacheds-kerberos-codec:2.0.0-M24') - testCompile('org.apache.directory.server:apacheds-protocol-ldap:2.0.0-M24') - testCompile('org.apache.directory.server:apacheds-protocol-shared:2.0.0-M24') - testCompile('org.apache.directory.jdbm:apacheds-jdbm1:2.0.0-M3') - testCompile('org.apache.directory.server:apacheds-jdbm-partition:2.0.0-M24') - testCompile('org.apache.directory.server:apacheds-xdbm-partition:2.0.0-M24') - testCompile('org.apache.directory.api:api-ldap-extras-sp:1.0.0') - testCompile('org.apache.directory.server:apacheds-test-framework:2.0.0-M24') - testCompile('org.apache.directory.server:apacheds-core-annotations:2.0.0-M24') - testCompile('org.apache.directory.server:apacheds-ldif-partition:2.0.0-M24') - testCompile('org.apache.directory.server:apacheds-mavibot-partition:2.0.0-M24') - testCompile('org.apache.directory.server:apacheds-protocol-kerberos:2.0.0-M24') - testCompile('org.apache.directory.server:apacheds-server-annotations:2.0.0-M24') - testCompile('org.apache.directory.api:api-ldap-codec-standalone:1.0.0') - testCompile('org.apache.directory.api:api-ldap-net-mina:1.0.0') - testCompile('org.apache.directory.server:ldap-client-test:2.0.0-M24') - testCompile('org.apache.directory.server:apacheds-interceptor-kerberos:2.0.0-M24') - testCompile('org.apache.directory.mavibot:mavibot:1.0.0-M8') + testImplementation('org.apache.kerby:kerby-backend:1.1.1') + testImplementation('org.apache.kerby:ldap-backend:1.1.1') + testImplementation('org.apache.kerby:kerb-identity:1.1.1') + testImplementation('org.apache.directory.api:api-ldap-client-api:1.0.0') + testImplementation('org.apache.directory.api:api-ldap-schema-data:1.0.0') + testImplementation('org.apache.directory.api:api-ldap-codec-core:1.0.0') + testImplementation('org.apache.directory.api:api-ldap-extras-aci:1.0.0') + testImplementation('org.apache.directory.api:api-ldap-extras-codec:1.0.0') + testImplementation('org.apache.directory.api:api-ldap-extras-codec-api:1.0.0') + testImplementation('commons-pool:commons-pool:1.6') + testImplementation('commons-collections:commons-collections:3.2.2') + testImplementation('org.apache.mina:mina-core:2.0.17') + testImplementation('org.apache.directory.api:api-util:1.0.1') + testImplementation('org.apache.directory.api:api-i18n:1.0.1') + testImplementation('org.apache.directory.api:api-ldap-model:1.0.1') + testImplementation('org.apache.directory.api:api-asn1-api:1.0.1') + testImplementation('org.apache.directory.api:api-asn1-ber:1.0.1') + testImplementation('org.apache.servicemix.bundles:org.apache.servicemix.bundles.antlr:2.7.7_5') + testImplementation('org.apache.directory.server:apacheds-core-api:2.0.0-M24') + testImplementation('org.apache.directory.server:apacheds-i18n:2.0.0-M24') + testImplementation('org.apache.directory.api:api-ldap-extras-util:1.0.0') + testImplementation('net.sf.ehcache:ehcache:2.10.4') + testImplementation('org.apache.directory.server:apacheds-kerberos-codec:2.0.0-M24') + testImplementation('org.apache.directory.server:apacheds-protocol-ldap:2.0.0-M24') + testImplementation('org.apache.directory.server:apacheds-protocol-shared:2.0.0-M24') + testImplementation('org.apache.directory.jdbm:apacheds-jdbm1:2.0.0-M3') + testImplementation('org.apache.directory.server:apacheds-jdbm-partition:2.0.0-M24') + testImplementation('org.apache.directory.server:apacheds-xdbm-partition:2.0.0-M24') + testImplementation('org.apache.directory.api:api-ldap-extras-sp:1.0.0') + testImplementation('org.apache.directory.server:apacheds-test-framework:2.0.0-M24') + testImplementation('org.apache.directory.server:apacheds-core-annotations:2.0.0-M24') + testImplementation('org.apache.directory.server:apacheds-ldif-partition:2.0.0-M24') + testImplementation('org.apache.directory.server:apacheds-mavibot-partition:2.0.0-M24') + testImplementation('org.apache.directory.server:apacheds-protocol-kerberos:2.0.0-M24') + testImplementation('org.apache.directory.server:apacheds-server-annotations:2.0.0-M24') + testImplementation('org.apache.directory.api:api-ldap-codec-standalone:1.0.0') + testImplementation('org.apache.directory.api:api-ldap-net-mina:1.0.0') + testImplementation('org.apache.directory.server:ldap-client-test:2.0.0-M24') + testImplementation('org.apache.directory.server:apacheds-interceptor-kerberos:2.0.0-M24') + testImplementation('org.apache.directory.mavibot:mavibot:1.0.0-M8') } compileJava.options.compilerArgs << "-Xlint:-rawtypes,-unchecked" @@ -144,6 +143,7 @@ processTestResources { configurations { testArtifacts.extendsFrom testRuntime + testArtifacts.extendsFrom testImplementation } task testJar(type: Jar) { appendix 'test' @@ -493,4 +493,3 @@ gradle.projectsEvaluated { .findAll { it.path.startsWith(project.path + ":qa") } .each { check.dependsOn it.check } } - diff --git a/x-pack/plugin/security/cli/build.gradle b/x-pack/plugin/security/cli/build.gradle index 78048537bfbbc..2a201622b81bc 100644 --- a/x-pack/plugin/security/cli/build.gradle +++ b/x-pack/plugin/security/cli/build.gradle @@ -10,9 +10,13 @@ dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') compile "org.bouncycastle:bcpkix-jdk15on:${versions.bouncycastle}" compile "org.bouncycastle:bcprov-jdk15on:${versions.bouncycastle}" - testImplementation 'com.google.jimfs:jimfs:1.1' - testCompile project(":test:framework") - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation('com.google.jimfs:jimfs:1.1') { + // this is provided by the runtime classpath, from the security project + exclude group: 'com.google.guava', module: 'guava' + } + testRuntimeOnly 'com.google.guava:guava:19.0' + testImplementation project(":test:framework") + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } dependencyLicenses { diff --git a/x-pack/plugin/security/qa/basic-enable-security/build.gradle b/x-pack/plugin/security/qa/basic-enable-security/build.gradle index 8ffec1dc6d8a5..660468afe2650 100644 --- a/x-pack/plugin/security/qa/basic-enable-security/build.gradle +++ b/x-pack/plugin/security/qa/basic-enable-security/build.gradle @@ -5,9 +5,9 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } integTest { diff --git a/x-pack/plugin/security/qa/security-basic/build.gradle b/x-pack/plugin/security/qa/security-basic/build.gradle index 0b51fba9667a6..b5c72933cdabd 100644 --- a/x-pack/plugin/security/qa/security-basic/build.gradle +++ b/x-pack/plugin/security/qa/security-basic/build.gradle @@ -3,9 +3,9 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } testClusters.integTest { diff --git a/x-pack/plugin/security/qa/security-disabled/build.gradle b/x-pack/plugin/security/qa/security-disabled/build.gradle index b96bafd280c96..caa0cfe757f5f 100644 --- a/x-pack/plugin/security/qa/security-disabled/build.gradle +++ b/x-pack/plugin/security/qa/security-disabled/build.gradle @@ -11,9 +11,9 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } testClusters.integTest { diff --git a/x-pack/plugin/security/qa/security-not-enabled/build.gradle b/x-pack/plugin/security/qa/security-not-enabled/build.gradle index ecaa662a99db2..bfd3cd661a59c 100644 --- a/x-pack/plugin/security/qa/security-not-enabled/build.gradle +++ b/x-pack/plugin/security/qa/security-not-enabled/build.gradle @@ -11,9 +11,9 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } testClusters.integTest { diff --git a/x-pack/plugin/security/qa/security-trial/build.gradle b/x-pack/plugin/security/qa/security-trial/build.gradle index e8e0b547c1828..26045bb9ec4e4 100644 --- a/x-pack/plugin/security/qa/security-trial/build.gradle +++ b/x-pack/plugin/security/qa/security-trial/build.gradle @@ -3,9 +3,9 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } testClusters.integTest { diff --git a/x-pack/plugin/security/qa/tls-basic/build.gradle b/x-pack/plugin/security/qa/tls-basic/build.gradle index e3b4104161294..9701a573b3e8f 100644 --- a/x-pack/plugin/security/qa/tls-basic/build.gradle +++ b/x-pack/plugin/security/qa/tls-basic/build.gradle @@ -3,9 +3,9 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } forbiddenPatterns { diff --git a/x-pack/plugin/spatial/build.gradle b/x-pack/plugin/spatial/build.gradle index 858ee5e6df538..ed2e617fb95b1 100644 --- a/x-pack/plugin/spatial/build.gradle +++ b/x-pack/plugin/spatial/build.gradle @@ -11,7 +11,7 @@ esplugin { dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } // xpack modules are installed in real clusters as the meta plugin, so diff --git a/x-pack/plugin/sql/build.gradle b/x-pack/plugin/sql/build.gradle index 8147e8222d91d..a5320298bd9c4 100644 --- a/x-pack/plugin/sql/build.gradle +++ b/x-pack/plugin/sql/build.gradle @@ -40,13 +40,13 @@ dependencies { compile project(':modules:aggs-matrix-stats') compile "org.antlr:antlr4-runtime:${antlrVersion}" compileOnly project(path: xpackModule('ql'), configuration: 'default') - testCompile project(':test:framework') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('ql'), configuration: 'testArtifacts') - testCompile project(path: ':modules:reindex', configuration: 'runtime') - testCompile project(path: ':modules:parent-join', configuration: 'runtime') - testCompile project(path: ':modules:analysis-common', configuration: 'runtime') + testImplementation project(':test:framework') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('ql'), configuration: 'testArtifacts') + testImplementation project(path: ':modules:reindex', configuration: 'runtime') + testImplementation project(path: ':modules:parent-join', configuration: 'runtime') + testImplementation project(path: ':modules:analysis-common', configuration: 'runtime') bin(project(path: xpackModule('sql:sql-cli'), configuration: 'shadow')) } diff --git a/x-pack/plugin/sql/jdbc/build.gradle b/x-pack/plugin/sql/jdbc/build.gradle index 256141a9e5eb4..48b8a84a0934b 100644 --- a/x-pack/plugin/sql/jdbc/build.gradle +++ b/x-pack/plugin/sql/jdbc/build.gradle @@ -26,8 +26,8 @@ dependencies { compile project(':libs:elasticsearch-core') compile "com.fasterxml.jackson.dataformat:jackson-dataformat-cbor:${versions.jackson}" runtime "com.fasterxml.jackson.core:jackson-core:${versions.jackson}" - testCompile project(":test:framework") - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(":test:framework") + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } dependencyLicenses { diff --git a/x-pack/plugin/sql/qa/jdbc/build.gradle b/x-pack/plugin/sql/qa/jdbc/build.gradle index 3f2b503d5f73a..ffbd8b3cf2271 100644 --- a/x-pack/plugin/sql/qa/jdbc/build.gradle +++ b/x-pack/plugin/sql/qa/jdbc/build.gradle @@ -39,10 +39,10 @@ subprojects { * dependencies but we don't really want them because they cause * all kinds of trouble with the jar hell checks. So we suppress * them explicitly for non-es projects. */ - testCompile(xpackProject('plugin:sql:qa:jdbc')) { + testImplementation(xpackProject('plugin:sql:qa:jdbc')) { transitive = false } - testCompile project(":test:framework") + testImplementation project(":test:framework") testRuntime project(path: xpackModule('sql:jdbc')) } diff --git a/x-pack/plugin/sql/qa/jdbc/security/build.gradle b/x-pack/plugin/sql/qa/jdbc/security/build.gradle index d107b61faebe3..16230b2434def 100644 --- a/x-pack/plugin/sql/qa/jdbc/security/build.gradle +++ b/x-pack/plugin/sql/qa/jdbc/security/build.gradle @@ -1,5 +1,5 @@ dependencies { - testCompile project(':x-pack:plugin:core') + testImplementation project(':x-pack:plugin:core') } Project mainProject = project @@ -23,7 +23,7 @@ subprojects { configurations.create('testArtifacts') dependencies { - testCompile project(":x-pack:plugin:core") + testImplementation project(":x-pack:plugin:core") testArtifacts project(path: mainProject.path, configuration: 'testArtifacts') } diff --git a/x-pack/plugin/sql/qa/server/build.gradle b/x-pack/plugin/sql/qa/server/build.gradle index ef0b9adcff16f..9b30a7b03bac0 100644 --- a/x-pack/plugin/sql/qa/server/build.gradle +++ b/x-pack/plugin/sql/qa/server/build.gradle @@ -64,10 +64,10 @@ subprojects { * dependencies but we don't really want them because they cause * all kinds of trouble with the jar hell checks. So we suppress * them explicitly for non-es projects. */ - testCompile(xpackProject('plugin:sql:qa:server')) { + testImplementation(xpackProject('plugin:sql:qa:server')) { transitive = false } - testCompile project(":test:framework") + testImplementation project(":test:framework") // JDBC testing dependencies testRuntime "net.sourceforge.csvjdbc:csvjdbc:${csvjdbcVersion}" diff --git a/x-pack/plugin/sql/qa/server/security/build.gradle b/x-pack/plugin/sql/qa/server/security/build.gradle index 8c2bc24795fbd..8fd4cbfbba821 100644 --- a/x-pack/plugin/sql/qa/server/security/build.gradle +++ b/x-pack/plugin/sql/qa/server/security/build.gradle @@ -1,5 +1,5 @@ dependencies { - testCompile project(':x-pack:plugin:core') + testImplementation project(':x-pack:plugin:core') } Project mainProject = project @@ -23,7 +23,7 @@ subprojects { configurations.create('testArtifacts') dependencies { - testCompile project(":x-pack:plugin:core") + testImplementation project(":x-pack:plugin:core") testArtifacts project(path: mainProject.path, configuration: 'testArtifacts') } diff --git a/x-pack/plugin/sql/sql-action/build.gradle b/x-pack/plugin/sql/sql-action/build.gradle index 4e74d9be35375..2908017d4f6d3 100644 --- a/x-pack/plugin/sql/sql-action/build.gradle +++ b/x-pack/plugin/sql/sql-action/build.gradle @@ -25,7 +25,7 @@ dependencies { runtime "org.apache.logging.log4j:log4j-api:${versions.log4j}" runtime "org.apache.logging.log4j:log4j-core:${versions.log4j}" - testCompile project(":test:framework") + testImplementation project(":test:framework") } forbiddenApisMain { diff --git a/x-pack/plugin/sql/sql-cli/build.gradle b/x-pack/plugin/sql/sql-cli/build.gradle index 2b7e44365089e..91cf9e42cd5f1 100644 --- a/x-pack/plugin/sql/sql-cli/build.gradle +++ b/x-pack/plugin/sql/sql-cli/build.gradle @@ -31,7 +31,7 @@ dependencies { compile project(":libs:elasticsearch-cli") compile project(':libs:elasticsearch-x-content') runtime "org.elasticsearch:jna:${versions.jna}" - testCompile project(":test:framework") + testImplementation project(":test:framework") } dependencyLicenses { diff --git a/x-pack/plugin/sql/sql-client/build.gradle b/x-pack/plugin/sql/sql-client/build.gradle index 0679a3fe5097b..59b5a1e29773d 100644 --- a/x-pack/plugin/sql/sql-client/build.gradle +++ b/x-pack/plugin/sql/sql-client/build.gradle @@ -9,8 +9,8 @@ description = 'Code shared between jdbc and cli' dependencies { compile xpackProject('plugin:sql:sql-proto') compile "com.fasterxml.jackson.core:jackson-core:${versions.jackson}" - testCompile project(":test:framework") - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(":test:framework") + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } dependencyLicenses { diff --git a/x-pack/plugin/sql/sql-proto/build.gradle b/x-pack/plugin/sql/sql-proto/build.gradle index dac036ecf6b92..6082db8cbbbb3 100644 --- a/x-pack/plugin/sql/sql-proto/build.gradle +++ b/x-pack/plugin/sql/sql-proto/build.gradle @@ -15,7 +15,7 @@ dependencies { } runtime "com.fasterxml.jackson.core:jackson-core:${versions.jackson}" - testCompile project(":test:framework") + testImplementation project(":test:framework") } forbiddenApisMain { diff --git a/x-pack/plugin/transform/build.gradle b/x-pack/plugin/transform/build.gradle index 8e7375ddf2a82..93251a19e58ec 100644 --- a/x-pack/plugin/transform/build.gradle +++ b/x-pack/plugin/transform/build.gradle @@ -12,9 +12,9 @@ dependencies { compileOnly project(":server") compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('analytics'), configuration: 'runtime') - testCompile project(path: ':modules:aggs-matrix-stats', configuration: 'runtime') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('analytics'), configuration: 'runtime') + testImplementation project(path: ':modules:aggs-matrix-stats', configuration: 'runtime') } // xpack modules are installed in real clusters as the meta plugin, so diff --git a/x-pack/plugin/transform/qa/multi-node-tests/build.gradle b/x-pack/plugin/transform/qa/multi-node-tests/build.gradle index 652a7a1abe31b..dcfe9c3aa1fe8 100644 --- a/x-pack/plugin/transform/qa/multi-node-tests/build.gradle +++ b/x-pack/plugin/transform/qa/multi-node-tests/build.gradle @@ -3,10 +3,10 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('transform'), configuration: 'runtime') - testCompile project(':client:rest-high-level') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('transform'), configuration: 'runtime') + testImplementation project(':client:rest-high-level') } // location for keys and certificates diff --git a/x-pack/plugin/transform/qa/single-node-tests/build.gradle b/x-pack/plugin/transform/qa/single-node-tests/build.gradle index 95cb164ff9ac0..b16b57674e665 100644 --- a/x-pack/plugin/transform/qa/single-node-tests/build.gradle +++ b/x-pack/plugin/transform/qa/single-node-tests/build.gradle @@ -3,10 +3,10 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('transform'), configuration: 'runtime') - testCompile project(':client:rest-high-level') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('transform'), configuration: 'runtime') + testImplementation project(':client:rest-high-level') } testClusters.integTest { diff --git a/x-pack/plugin/vectors/build.gradle b/x-pack/plugin/vectors/build.gradle index 26c1549859c8e..5613f9da801e2 100644 --- a/x-pack/plugin/vectors/build.gradle +++ b/x-pack/plugin/vectors/build.gradle @@ -13,7 +13,7 @@ archivesBaseName = 'x-pack-vectors' dependencies { compileOnly project(':modules:lang-painless:spi') compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } integTest.enabled = false diff --git a/x-pack/plugin/voting-only-node/build.gradle b/x-pack/plugin/voting-only-node/build.gradle index 7fbf027c47f46..2b5a4668d4ec0 100644 --- a/x-pack/plugin/voting-only-node/build.gradle +++ b/x-pack/plugin/voting-only-node/build.gradle @@ -10,7 +10,7 @@ esplugin { dependencies { compileOnly project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } // xpack modules are installed in real clusters as the meta plugin, so diff --git a/x-pack/plugin/watcher/build.gradle b/x-pack/plugin/watcher/build.gradle index 0c67c7d9dc7e3..2cfbaee518cde 100644 --- a/x-pack/plugin/watcher/build.gradle +++ b/x-pack/plugin/watcher/build.gradle @@ -30,8 +30,8 @@ dependencies { compileOnly project(path: ':modules:transport-netty4', configuration: 'runtime') compileOnly project(path: ':plugins:transport-nio', configuration: 'runtime') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(xpackModule('ilm')) + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(xpackModule('ilm')) // watcher deps compile 'com.googlecode.owasp-java-html-sanitizer:owasp-java-html-sanitizer:20191001.1' @@ -42,9 +42,9 @@ dependencies { compileOnly "org.apache.httpcomponents:httpclient:${versions.httpclient}" compileOnly "org.apache.httpcomponents:httpcore:${versions.httpcore}" - testCompile 'org.subethamail:subethasmtp:3.1.7' + testImplementation 'org.subethamail:subethasmtp:3.1.7' // needed for subethasmtp, has @GuardedBy annotation - testCompile 'com.google.code.findbugs:jsr305:3.0.2' + testImplementation 'com.google.code.findbugs:jsr305:3.0.2' } // classes are missing, e.g. com.ibm.icu.lang.UCharacter diff --git a/x-pack/plugin/watcher/qa/rest/build.gradle b/x-pack/plugin/watcher/qa/rest/build.gradle index 798b906ca4e1a..dfdbe63a728bd 100644 --- a/x-pack/plugin/watcher/qa/rest/build.gradle +++ b/x-pack/plugin/watcher/qa/rest/build.gradle @@ -3,11 +3,12 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(':x-pack:qa') + testImplementation project(':x-pack:qa') } configurations { testArtifacts.extendsFrom testRuntime + testArtifacts.extendsFrom testImplementation } task testJar(type: Jar) { diff --git a/x-pack/plugin/watcher/qa/with-monitoring/build.gradle b/x-pack/plugin/watcher/qa/with-monitoring/build.gradle index 1a03334f09da8..81e95bade5683 100644 --- a/x-pack/plugin/watcher/qa/with-monitoring/build.gradle +++ b/x-pack/plugin/watcher/qa/with-monitoring/build.gradle @@ -3,7 +3,7 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(':x-pack:qa') + testImplementation project(':x-pack:qa') } testClusters.integTest { diff --git a/x-pack/plugin/watcher/qa/with-security/build.gradle b/x-pack/plugin/watcher/qa/with-security/build.gradle index 244242b2c5509..4207af1112f85 100644 --- a/x-pack/plugin/watcher/qa/with-security/build.gradle +++ b/x-pack/plugin/watcher/qa/with-security/build.gradle @@ -3,8 +3,8 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(':x-pack:qa') - testCompile project(path: ':x-pack:plugin:watcher:qa:rest', configuration: 'testArtifacts') + testImplementation project(':x-pack:qa') + testImplementation project(path: ':x-pack:plugin:watcher:qa:rest', configuration: 'testArtifacts') restXpackTestConfig project(path: ':x-pack:plugin:watcher:qa:rest', configuration: 'restXpackTests') } diff --git a/x-pack/qa/core-rest-tests-with-security/build.gradle b/x-pack/qa/core-rest-tests-with-security/build.gradle index 4fc4428c8ed6f..98a2c8afe20eb 100644 --- a/x-pack/qa/core-rest-tests-with-security/build.gradle +++ b/x-pack/qa/core-rest-tests-with-security/build.gradle @@ -3,7 +3,7 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(':x-pack:qa') + testImplementation project(':x-pack:qa') } restResources { diff --git a/x-pack/qa/evil-tests/build.gradle b/x-pack/qa/evil-tests/build.gradle index b90ab6dd33624..a57b259996dd7 100644 --- a/x-pack/qa/evil-tests/build.gradle +++ b/x-pack/qa/evil-tests/build.gradle @@ -1,7 +1,7 @@ apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') } test { diff --git a/x-pack/qa/full-cluster-restart/build.gradle b/x-pack/qa/full-cluster-restart/build.gradle index d59bed7b6c8a2..dc49ead6f3d35 100644 --- a/x-pack/qa/full-cluster-restart/build.gradle +++ b/x-pack/qa/full-cluster-restart/build.gradle @@ -9,10 +9,10 @@ apply from : "$rootDir/gradle/bwc-test.gradle" dependencies { // TODO: Remove core dependency and change tests to not use builders that are part of xpack-core. // Currently needed for ml tests are using the building for datafeed and job config) - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: ':qa:full-cluster-restart', configuration: 'testArtifacts') - testCompile project(':x-pack:qa') + testImplementation project(path: ':qa:full-cluster-restart', configuration: 'testArtifacts') + testImplementation project(':x-pack:qa') } licenseHeaders { diff --git a/x-pack/qa/kerberos-tests/build.gradle b/x-pack/qa/kerberos-tests/build.gradle index 430db18427afd..1f7a6fe255e0e 100644 --- a/x-pack/qa/kerberos-tests/build.gradle +++ b/x-pack/qa/kerberos-tests/build.gradle @@ -9,9 +9,9 @@ apply plugin: 'elasticsearch.test.fixtures' testFixtures.useFixture ":test:fixtures:krb5kdc-fixture", "peppa" dependencies { - testCompile project(':x-pack:plugin:core') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(':x-pack:plugin:core') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') } testClusters.integTest { diff --git a/x-pack/qa/multi-cluster-search-security/build.gradle b/x-pack/qa/multi-cluster-search-security/build.gradle index 75f8af8f44b65..d55099557ae6c 100644 --- a/x-pack/qa/multi-cluster-search-security/build.gradle +++ b/x-pack/qa/multi-cluster-search-security/build.gradle @@ -4,7 +4,7 @@ apply plugin: 'elasticsearch.testclusters' apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(':x-pack:qa') + testImplementation project(':x-pack:qa') } restResources { diff --git a/x-pack/qa/multi-cluster-tests-with-security/build.gradle b/x-pack/qa/multi-cluster-tests-with-security/build.gradle index 7dc422447bd1a..09da9b788ddde 100644 --- a/x-pack/qa/multi-cluster-tests-with-security/build.gradle +++ b/x-pack/qa/multi-cluster-tests-with-security/build.gradle @@ -4,8 +4,8 @@ apply plugin: 'elasticsearch.testclusters' apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(':x-pack:qa') - testCompile project(':client:rest-high-level') + testImplementation project(':x-pack:qa') + testImplementation project(':client:rest-high-level') } restResources { diff --git a/x-pack/qa/multi-node/build.gradle b/x-pack/qa/multi-node/build.gradle index 331ae0625271a..e6ce810dbbe05 100644 --- a/x-pack/qa/multi-node/build.gradle +++ b/x-pack/qa/multi-node/build.gradle @@ -3,7 +3,7 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(':x-pack:qa') + testImplementation project(':x-pack:qa') } testClusters.integTest { diff --git a/x-pack/qa/oidc-op-tests/build.gradle b/x-pack/qa/oidc-op-tests/build.gradle index 86a53e5487695..62b03c55c8088 100644 --- a/x-pack/qa/oidc-op-tests/build.gradle +++ b/x-pack/qa/oidc-op-tests/build.gradle @@ -6,9 +6,9 @@ apply plugin: 'elasticsearch.rest-test' apply plugin: 'elasticsearch.test.fixtures' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') } testFixtures.useFixture ":x-pack:test:idp-fixture", "oidc-provider" diff --git a/x-pack/qa/openldap-tests/build.gradle b/x-pack/qa/openldap-tests/build.gradle index 9bd0e66983816..e873e2e4ab4ac 100644 --- a/x-pack/qa/openldap-tests/build.gradle +++ b/x-pack/qa/openldap-tests/build.gradle @@ -2,9 +2,9 @@ apply plugin: 'elasticsearch.standalone-test' apply plugin: 'elasticsearch.test.fixtures' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } testFixtures.useFixture ":x-pack:test:idp-fixture", "openldap" diff --git a/x-pack/qa/password-protected-keystore/build.gradle b/x-pack/qa/password-protected-keystore/build.gradle index 8accfa742bd95..4df471ad2de9c 100644 --- a/x-pack/qa/password-protected-keystore/build.gradle +++ b/x-pack/qa/password-protected-keystore/build.gradle @@ -26,7 +26,7 @@ apply plugin: 'elasticsearch.testclusters' apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('core'), configuration: 'default') } testClusters.integTest { diff --git a/x-pack/qa/reindex-tests-with-security/build.gradle b/x-pack/qa/reindex-tests-with-security/build.gradle index 969fdba727ea8..120ffc4a25932 100644 --- a/x-pack/qa/reindex-tests-with-security/build.gradle +++ b/x-pack/qa/reindex-tests-with-security/build.gradle @@ -5,10 +5,10 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile project(path: ':modules:reindex') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: ':modules:reindex') } forbiddenPatterns { diff --git a/x-pack/qa/rolling-upgrade-basic/build.gradle b/x-pack/qa/rolling-upgrade-basic/build.gradle index 472606b1dce6d..ffd702836ef4b 100644 --- a/x-pack/qa/rolling-upgrade-basic/build.gradle +++ b/x-pack/qa/rolling-upgrade-basic/build.gradle @@ -7,7 +7,7 @@ apply plugin: 'elasticsearch.standalone-test' apply from : "$rootDir/gradle/bwc-test.gradle" dependencies { - testCompile project(':x-pack:qa') + testImplementation project(':x-pack:qa') } for (Version bwcVersion : BuildParams.bwcVersions.wireCompatible) { diff --git a/x-pack/qa/rolling-upgrade-multi-cluster/build.gradle b/x-pack/qa/rolling-upgrade-multi-cluster/build.gradle index 2f27713b19ee4..8e678294fc7f8 100644 --- a/x-pack/qa/rolling-upgrade-multi-cluster/build.gradle +++ b/x-pack/qa/rolling-upgrade-multi-cluster/build.gradle @@ -7,7 +7,7 @@ apply plugin: 'elasticsearch.standalone-test' apply from : "$rootDir/gradle/bwc-test.gradle" dependencies { - testCompile project(':x-pack:qa') + testImplementation project(':x-pack:qa') } for (Version bwcVersion : BuildParams.bwcVersions.wireCompatible) { diff --git a/x-pack/qa/rolling-upgrade/build.gradle b/x-pack/qa/rolling-upgrade/build.gradle index 4eaf0fae5060c..28cad6b801cd6 100644 --- a/x-pack/qa/rolling-upgrade/build.gradle +++ b/x-pack/qa/rolling-upgrade/build.gradle @@ -7,8 +7,8 @@ apply plugin: 'elasticsearch.standalone-test' apply from : "$rootDir/gradle/bwc-test.gradle" dependencies { - testCompile project(':x-pack:qa') - testCompile project(':client:rest-high-level') + testImplementation project(':x-pack:qa') + testImplementation project(':client:rest-high-level') } restResources { diff --git a/x-pack/qa/saml-idp-tests/build.gradle b/x-pack/qa/saml-idp-tests/build.gradle index 5d7cb84acf6f5..838d5614f37d1 100644 --- a/x-pack/qa/saml-idp-tests/build.gradle +++ b/x-pack/qa/saml-idp-tests/build.gradle @@ -6,8 +6,8 @@ apply plugin: 'elasticsearch.rest-test' apply plugin: 'elasticsearch.test.fixtures' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') - testCompile 'com.google.jimfs:jimfs:1.1' + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation 'com.google.jimfs:jimfs:1.1' } testFixtures.useFixture ":x-pack:test:idp-fixture" diff --git a/x-pack/qa/security-client-tests/build.gradle b/x-pack/qa/security-client-tests/build.gradle index 10e35967efb4c..b1eeeabd6853d 100644 --- a/x-pack/qa/security-client-tests/build.gradle +++ b/x-pack/qa/security-client-tests/build.gradle @@ -2,8 +2,8 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(xpackModule('core')) - testCompile project(path: xpackProject('transport-client').path, configuration: 'runtime') + testImplementation project(xpackModule('core')) + testImplementation project(path: xpackProject('transport-client').path, configuration: 'runtime') } String outputDir = "${buildDir}/generated-resources/${project.name}" diff --git a/x-pack/qa/security-example-spi-extension/build.gradle b/x-pack/qa/security-example-spi-extension/build.gradle index eab1d89397812..f3088307faab3 100644 --- a/x-pack/qa/security-example-spi-extension/build.gradle +++ b/x-pack/qa/security-example-spi-extension/build.gradle @@ -10,7 +10,7 @@ esplugin { dependencies { compileOnly project(':x-pack:plugin:core') - testCompile project(path: xpackProject('transport-client').path, configuration: 'runtime') + testImplementation project(path: xpackProject('transport-client').path, configuration: 'runtime') } diff --git a/x-pack/qa/security-migrate-tests/build.gradle b/x-pack/qa/security-migrate-tests/build.gradle index 38a5a45ec2ec5..80fa3179d646f 100644 --- a/x-pack/qa/security-migrate-tests/build.gradle +++ b/x-pack/qa/security-migrate-tests/build.gradle @@ -2,9 +2,9 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(xpackModule('core')) - testCompile project(path: xpackModule('security'), configuration: 'runtime') - testCompile project(path: xpackProject('transport-client').path, configuration: 'runtime') + testImplementation project(xpackModule('core')) + testImplementation project(path: xpackModule('security'), configuration: 'runtime') + testImplementation project(path: xpackProject('transport-client').path, configuration: 'runtime') } testClusters.integTest { diff --git a/x-pack/qa/security-setup-password-tests/build.gradle b/x-pack/qa/security-setup-password-tests/build.gradle index e22af6ed80d6f..4e520f76e814d 100644 --- a/x-pack/qa/security-setup-password-tests/build.gradle +++ b/x-pack/qa/security-setup-password-tests/build.gradle @@ -3,9 +3,9 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(path: xpackModule('core'), configuration: 'default') - testCompile project(path: xpackModule('security'), configuration: 'runtime') - testCompile project(path: xpackModule('core'), configuration: 'testArtifacts') + testImplementation project(path: xpackModule('core'), configuration: 'default') + testImplementation project(path: xpackModule('security'), configuration: 'runtime') + testImplementation project(path: xpackModule('core'), configuration: 'testArtifacts') } integTest.runner { diff --git a/x-pack/qa/security-tools-tests/build.gradle b/x-pack/qa/security-tools-tests/build.gradle index 135f82bb4a617..f8369a0bb013f 100644 --- a/x-pack/qa/security-tools-tests/build.gradle +++ b/x-pack/qa/security-tools-tests/build.gradle @@ -1,10 +1,10 @@ apply plugin: 'elasticsearch.standalone-test' dependencies { - testCompile project(xpackModule('security')) - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') - testCompile 'com.google.jimfs:jimfs:1.1' - testCompile 'com.google.guava:guava:16.0.1' + testImplementation project(xpackModule('security')) + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation 'com.google.jimfs:jimfs:1.1' + testImplementation 'com.google.guava:guava:16.0.1' } // add test resources from security, so certificate tool tests can use example certs diff --git a/x-pack/qa/smoke-test-plugins-ssl/build.gradle b/x-pack/qa/smoke-test-plugins-ssl/build.gradle index 1929b1f3eaf6f..8d5e6e3a8de18 100644 --- a/x-pack/qa/smoke-test-plugins-ssl/build.gradle +++ b/x-pack/qa/smoke-test-plugins-ssl/build.gradle @@ -7,7 +7,7 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(':x-pack:plugin:core') + testImplementation project(':x-pack:plugin:core') } String outputDir = "${buildDir}/generated-resources/${project.name}" diff --git a/x-pack/qa/smoke-test-plugins/build.gradle b/x-pack/qa/smoke-test-plugins/build.gradle index be17bfe3558c8..faf4e1ed58c5c 100644 --- a/x-pack/qa/smoke-test-plugins/build.gradle +++ b/x-pack/qa/smoke-test-plugins/build.gradle @@ -5,7 +5,7 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(':x-pack:qa') + testImplementation project(':x-pack:qa') } int pluginsCount = 0 diff --git a/x-pack/qa/smoke-test-security-with-mustache/build.gradle b/x-pack/qa/smoke-test-security-with-mustache/build.gradle index 3c38b9ae8f30f..c89c82400e1e1 100644 --- a/x-pack/qa/smoke-test-security-with-mustache/build.gradle +++ b/x-pack/qa/smoke-test-security-with-mustache/build.gradle @@ -3,7 +3,7 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(':x-pack:qa') + testImplementation project(':x-pack:qa') } restResources { diff --git a/x-pack/qa/third-party/active-directory/build.gradle b/x-pack/qa/third-party/active-directory/build.gradle index 02c3d0aec124d..6f4f4d9239b78 100644 --- a/x-pack/qa/third-party/active-directory/build.gradle +++ b/x-pack/qa/third-party/active-directory/build.gradle @@ -2,8 +2,8 @@ apply plugin: 'elasticsearch.standalone-test' apply plugin: 'elasticsearch.test.fixtures' dependencies { - testCompile project(xpackModule('security')) - testCompile project(path: xpackModule('security'), configuration: 'testArtifacts') + testImplementation project(xpackModule('security')) + testImplementation project(path: xpackModule('security'), configuration: 'testArtifacts') } testFixtures.useFixture ":x-pack:test:smb-fixture" diff --git a/x-pack/qa/third-party/jira/build.gradle b/x-pack/qa/third-party/jira/build.gradle index f2642d7150049..9c24a69ddaff9 100644 --- a/x-pack/qa/third-party/jira/build.gradle +++ b/x-pack/qa/third-party/jira/build.gradle @@ -8,8 +8,8 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(':x-pack:plugin:core') - testCompile project(path: xpackModule('watcher'), configuration: 'runtime') + testImplementation project(':x-pack:plugin:core') + testImplementation project(path: xpackModule('watcher'), configuration: 'runtime') } restResources { diff --git a/x-pack/qa/third-party/pagerduty/build.gradle b/x-pack/qa/third-party/pagerduty/build.gradle index c65f04118e0d3..3aa67dd69c53e 100644 --- a/x-pack/qa/third-party/pagerduty/build.gradle +++ b/x-pack/qa/third-party/pagerduty/build.gradle @@ -3,8 +3,8 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(':x-pack:plugin:core') - testCompile project(path: xpackModule('watcher'), configuration: 'runtime') + testImplementation project(':x-pack:plugin:core') + testImplementation project(path: xpackModule('watcher'), configuration: 'runtime') } String pagerDutyServiceKey = System.getenv('pagerduty_service_api_key') diff --git a/x-pack/qa/third-party/slack/build.gradle b/x-pack/qa/third-party/slack/build.gradle index a1b92050482bb..8e42670b47369 100644 --- a/x-pack/qa/third-party/slack/build.gradle +++ b/x-pack/qa/third-party/slack/build.gradle @@ -3,8 +3,8 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(':x-pack:plugin:core') - testCompile project(path: xpackModule('watcher'), configuration: 'runtime') + testImplementation project(':x-pack:plugin:core') + testImplementation project(path: xpackModule('watcher'), configuration: 'runtime') } restResources { diff --git a/x-pack/qa/transport-client-tests/build.gradle b/x-pack/qa/transport-client-tests/build.gradle index eec6735db4aac..05b7aff4ede30 100644 --- a/x-pack/qa/transport-client-tests/build.gradle +++ b/x-pack/qa/transport-client-tests/build.gradle @@ -2,8 +2,8 @@ apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { - testCompile project(xpackModule('core')) - testCompile project(path: xpackProject('transport-client').path, configuration: 'runtime') + testImplementation project(xpackModule('core')) + testImplementation project(path: xpackProject('transport-client').path, configuration: 'runtime') } testClusters.integTest { diff --git a/x-pack/snapshot-tool/build.gradle b/x-pack/snapshot-tool/build.gradle index 71dbeb0a073c4..2c474f268fb98 100644 --- a/x-pack/snapshot-tool/build.gradle +++ b/x-pack/snapshot-tool/build.gradle @@ -15,7 +15,7 @@ apply plugin: 'elasticsearch.build' dependencies { compile project(":server") compile project(":libs:elasticsearch-cli") - testCompile project(":test:framework") + testImplementation project(":test:framework") compile "com.amazonaws:aws-java-sdk-s3:${versions.aws}" compile "com.amazonaws:aws-java-sdk-core:${versions.aws}" diff --git a/x-pack/snapshot-tool/qa/google-cloud-storage/build.gradle b/x-pack/snapshot-tool/qa/google-cloud-storage/build.gradle index 0d84c1b623677..09b9ad96f7be2 100644 --- a/x-pack/snapshot-tool/qa/google-cloud-storage/build.gradle +++ b/x-pack/snapshot-tool/qa/google-cloud-storage/build.gradle @@ -9,9 +9,9 @@ apply plugin: 'elasticsearch.build' dependencies { compile project(":plugins:repository-gcs") - testCompile project(":test:framework") - testCompile project(':x-pack:snapshot-tool') - testCompile files(project(':x-pack:snapshot-tool').sourceSets.test.output) + testImplementation project(":test:framework") + testImplementation project(':x-pack:snapshot-tool') + testImplementation files(project(':x-pack:snapshot-tool').sourceSets.test.output) } test.enabled = false diff --git a/x-pack/snapshot-tool/qa/s3/build.gradle b/x-pack/snapshot-tool/qa/s3/build.gradle index 1aa0ee65cefcb..da5cf937ce875 100644 --- a/x-pack/snapshot-tool/qa/s3/build.gradle +++ b/x-pack/snapshot-tool/qa/s3/build.gradle @@ -7,9 +7,9 @@ apply plugin: 'elasticsearch.build' dependencies { compile project(":plugins:repository-s3") - testCompile project(":test:framework") - testCompile project(':x-pack:snapshot-tool') - testCompile files(project(':x-pack:snapshot-tool').sourceSets.test.output) + testImplementation project(":test:framework") + testImplementation project(':x-pack:snapshot-tool') + testImplementation files(project(':x-pack:snapshot-tool').sourceSets.test.output) } test.enabled = false diff --git a/x-pack/test/feature-aware/build.gradle b/x-pack/test/feature-aware/build.gradle index 9d7f1504418d2..83085eee33441 100644 --- a/x-pack/test/feature-aware/build.gradle +++ b/x-pack/test/feature-aware/build.gradle @@ -4,7 +4,7 @@ dependencies { compile 'org.ow2.asm:asm:7.1' compile project(':server') compile project(':x-pack:plugin:core') - testCompile project(':test:framework') + testImplementation project(':test:framework') } forbiddenApisMain.enabled = true diff --git a/x-pack/transport-client/build.gradle b/x-pack/transport-client/build.gradle index 0e7444ddb34b8..653936369469a 100644 --- a/x-pack/transport-client/build.gradle +++ b/x-pack/transport-client/build.gradle @@ -9,9 +9,9 @@ dependencies { // all of x-pack for now, and transport client will be going away in the future. compile project(xpackModule('core')) compile project(':client:transport') - testCompile "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" - testCompile "junit:junit:${versions.junit}" - testCompile "org.hamcrest:hamcrest:${versions.hamcrest}" + testImplementation "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" + testImplementation "junit:junit:${versions.junit}" + testImplementation "org.hamcrest:hamcrest:${versions.hamcrest}" } dependencyLicenses.enabled = false