From 7245d34f51802681fe1f413640d049db2417cbeb Mon Sep 17 00:00:00 2001 From: Ryan Ernst Date: Thu, 3 Dec 2015 22:48:51 -0800 Subject: [PATCH] add modules check to plugins smoke test --- qa/smoke-test-plugins/build.gradle | 32 ++++++++++++------- .../test/smoke_test_plugins/10_basic.yaml | 3 +- 2 files changed, 23 insertions(+), 12 deletions(-) diff --git a/qa/smoke-test-plugins/build.gradle b/qa/smoke-test-plugins/build.gradle index 864a58baf25..c169ddc4a08 100644 --- a/qa/smoke-test-plugins/build.gradle +++ b/qa/smoke-test-plugins/build.gradle @@ -21,21 +21,31 @@ import org.elasticsearch.gradle.MavenFilteringHack apply plugin: 'elasticsearch.rest-test' -ext.pluginCount = 0 -for (Project subproj : project.rootProject.subprojects) { - if (subproj.path.startsWith(':plugins:')) { - integTest { - cluster { - // need to get a non-decorated project object, so must re-lookup the project by path - plugin subproj.name, project(subproj.path) - } +ext.modulesCount = 0 +project.rootProject.subprojects.findAll { it.path.startsWith(':modules:') }.each { subproj -> + integTest { + cluster { + // need to get a non-decorated project object, so must re-lookup the project by path + module project(subproj.path) } - pluginCount += 1 } -} + modulesCount += 1 +} + +ext.pluginsCount = 0 +project.rootProject.subprojects.findAll { it.path.startsWith(':projects:') }.each { subproj -> + integTest { + cluster { + // need to get a non-decorated project object, so must re-lookup the project by path + plugin subproj.name, project(subproj.path) + } + } + pluginCount += 1 +} ext.expansions = [ - 'expected.plugin.count': pluginCount + 'expected.modules.count': modulesCount, + 'expected.plugins.count': pluginsCount ] processTestResources { diff --git a/qa/smoke-test-plugins/src/test/resources/rest-api-spec/test/smoke_test_plugins/10_basic.yaml b/qa/smoke-test-plugins/src/test/resources/rest-api-spec/test/smoke_test_plugins/10_basic.yaml index dbb09225fce..4d31ec4aca6 100644 --- a/qa/smoke-test-plugins/src/test/resources/rest-api-spec/test/smoke_test_plugins/10_basic.yaml +++ b/qa/smoke-test-plugins/src/test/resources/rest-api-spec/test/smoke_test_plugins/10_basic.yaml @@ -10,4 +10,5 @@ - do: nodes.info: {} - - length: { nodes.$master.plugins: ${expected.plugin.count} } + - length: { nodes.$master.modules: ${expected.modules.count} } + - length: { nodes.$master.plugins: ${expected.plugins.count} }