2018-01-27 00:48:30 -05:00
|
|
|
Project idpFixtureProject = xpackProject("test:idp-fixture")
|
|
|
|
evaluationDependsOn(idpFixtureProject.path)
|
|
|
|
|
2017-08-04 11:44:08 -04:00
|
|
|
apply plugin: 'elasticsearch.standalone-test'
|
|
|
|
apply plugin: 'elasticsearch.vagrantsupport'
|
|
|
|
|
|
|
|
dependencies {
|
2018-08-21 20:03:28 -04:00
|
|
|
// "org.elasticsearch.plugin:x-pack-core:${version}" doesn't work with idea because the testArtifacts are also here
|
|
|
|
testCompile project(path: xpackModule('core'), configuration: 'default')
|
2018-01-27 00:48:30 -05:00
|
|
|
testCompile project(path: xpackModule('security'), configuration: 'testArtifacts')
|
|
|
|
testCompile project(path: xpackModule('core'), configuration: 'testArtifacts')
|
2017-08-04 11:44:08 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
task openLdapFixture {
|
2018-01-27 00:48:30 -05:00
|
|
|
dependsOn "vagrantCheckVersion", "virtualboxCheckVersion", idpFixtureProject.up
|
2017-08-04 11:44:08 -04:00
|
|
|
}
|
|
|
|
|
2018-05-10 09:35:23 -04:00
|
|
|
String outputDir = "${project.buildDir}/generated-resources/${project.name}"
|
2018-02-07 19:42:25 -05:00
|
|
|
task copyIdpTrust(type: Copy) {
|
|
|
|
from idpFixtureProject.file('src/main/resources/certs/idptrust.jks');
|
2018-07-17 03:54:10 -04:00
|
|
|
from idpFixtureProject.file('src/main/resources/certs/ca.crt');
|
2018-02-07 19:42:25 -05:00
|
|
|
into outputDir
|
|
|
|
}
|
2017-08-04 11:44:08 -04:00
|
|
|
if (project.rootProject.vagrantSupported) {
|
2018-02-07 19:42:25 -05:00
|
|
|
project.sourceSets.test.output.dir(outputDir, builtBy: copyIdpTrust)
|
2017-08-04 11:44:08 -04:00
|
|
|
test.dependsOn openLdapFixture
|
2018-01-27 00:48:30 -05:00
|
|
|
test.finalizedBy idpFixtureProject.halt
|
2017-08-04 11:44:08 -04:00
|
|
|
} else {
|
|
|
|
test.enabled = false
|
2018-12-05 07:20:01 -05:00
|
|
|
testingConventions.enabled = false
|
2017-08-04 11:44:08 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
namingConventions {
|
|
|
|
// integ tests use Tests instead of IT
|
|
|
|
skipIntegTestInDisguise = true
|
|
|
|
}
|