From 4bbd4c25b0f4f2e98f5f1e23989d67dfc3c283e3 Mon Sep 17 00:00:00 2001 From: Ryan Ernst Date: Tue, 8 Dec 2015 17:26:53 -0800 Subject: [PATCH] Enable security manager for messy groovy tests Original commit: elastic/x-pack-elasticsearch@4b2b256a0452ffa9050123e4f220ff9bc018a8b0 --- .../qa/messy-test-watcher-with-groovy/build.gradle | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/elasticsearch/qa/messy-test-watcher-with-groovy/build.gradle b/elasticsearch/qa/messy-test-watcher-with-groovy/build.gradle index 23c31b51c5c..7dfab246e3e 100644 --- a/elasticsearch/qa/messy-test-watcher-with-groovy/build.gradle +++ b/elasticsearch/qa/messy-test-watcher-with-groovy/build.gradle @@ -11,8 +11,11 @@ dependencies { testCompile project(path: ':modules:lang-groovy', configuration: 'runtime') } -// TODO: remove this, its because gradle does not bring in plugin-metadata for lang-groovy -// into the test classpath: if it did, then things will work -test { - systemProperty 'tests.security.manager', 'false' +gradle.projectsEvaluated { + Project groovy = project(':modules:lang-groovy') + sourceSets.test.resources { + srcDir groovy.pluginProperties.generatedResourcesDir + srcDir new File(groovy.projectDir, 'src/main/plugin-metadata') + } + test.dependsOn groovy.pluginProperties }