import org.elasticsearch.gradle.test.RunTask apply plugin: 'elasticsearch.standalone-rest-test' apply plugin: 'elasticsearch.rest-test' dependencies { testCompile project(path: ':x-pack-elasticsearch:plugin', configuration: 'runtime') testCompile project(path: ':x-pack-elasticsearch:plugin', configuration: 'testArtifacts') testCompile project(path: ':modules:reindex') } // NOCOMMIT we should try this on multiple nodes integTestCluster { plugin ':x-pack-elasticsearch:plugin' setting 'xpack.ml.enabled', 'false' setting 'xpack.monitoring.enabled', 'false' extraConfigFile 'x-pack/roles.yml', 'roles.yml' setupCommand 'setupUser#test_admin', 'bin/x-pack/users', 'useradd', 'test_admin', '-p', 'x-pack-test-password', '-r', 'superuser' waitCondition = { node, ant -> File tmpFile = new File(node.cwd, 'wait.success') ant.get(src: "http://${node.httpUri()}/_cluster/health?wait_for_nodes=>=${numNodes}&wait_for_status=yellow", dest: tmpFile.toString(), username: 'test_admin', password: 'x-pack-test-password', ignoreerrors: true, retries: 10) return tmpFile.exists() } } task run(type: RunTask) { distribution = 'zip' // NOCOMMIT make double sure we want all the modules plugin ':x-pack-elasticsearch:plugin' setting 'xpack.ml.enabled', 'false' setting 'xpack.monitoring.enabled', 'false' extraConfigFile 'x-pack/roles.yml', 'roles.yml' setupCommand 'setupUser#test_admin', 'bin/x-pack/users', 'useradd', 'test_admin', '-p', 'x-pack-test-password', '-r', 'superuser' waitCondition = { node, ant -> File tmpFile = new File(node.cwd, 'wait.success') ant.get(src: "http://${node.httpUri()}/_cluster/health?wait_for_nodes=>=${numNodes}&wait_for_status=yellow", dest: tmpFile.toString(), username: 'test_admin', password: 'x-pack-test-password', ignoreerrors: true, retries: 10) return tmpFile.exists() } }