mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-02-06 13:08:29 +00:00
This PR moves the majority of the Watcher REST tests under the Watcher x-pack plugin. Specifically, moves the Watcher tests from: x-pack/plugin/test x-pack/qa/smoke-test-watcher x-pack/qa/smoke-test-watcher-with-security x-pack/qa/smoke-test-monitoring-with-watcher to: x-pack/plugin/watcher/qa/rest (/test and /qa/smoke-test-watcher) x-pack/plugin/watcher/qa/with-security x-pack/plugin/watcher/qa/with-monitoring Additionally, this disables Watcher from the main x-pack test cluster and consolidates the stop/start logic for the tests listed. No changes to the tests (beyond moving them) are included. 3rd party tests and doc tests (which also touch Watcher) are not included in the changes here.
43 lines
1.7 KiB
Groovy
43 lines
1.7 KiB
Groovy
apply plugin: 'elasticsearch.testclusters'
|
|
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')
|
|
}
|
|
|
|
|
|
// bring in watcher rest test suite from the rest project
|
|
task copyWatcherRestTests(type: Copy) {
|
|
into project.sourceSets.test.output.resourcesDir
|
|
from project(xpackProject('plugin:watcher:qa:rest').path).sourceSets.test.resources.srcDirs
|
|
include 'rest-api-spec/test/watcher/**'
|
|
}
|
|
|
|
restResources {
|
|
restApi {
|
|
includeXpack 'watcher', 'security', 'xpack'
|
|
}
|
|
}
|
|
|
|
integTest.runner.dependsOn copyWatcherRestTests
|
|
testClusters.integTest {
|
|
testDistribution = 'DEFAULT'
|
|
setting 'xpack.ilm.enabled', 'false'
|
|
setting 'xpack.monitoring.enabled', 'false'
|
|
setting 'xpack.ml.enabled', 'false'
|
|
setting 'xpack.security.enabled', 'true'
|
|
// settings to test settings filtering on
|
|
setting 'xpack.notification.email.account._email.smtp.host', 'host.domain'
|
|
setting 'xpack.notification.email.account._email.smtp.port', '587'
|
|
setting 'xpack.notification.email.account._email.smtp.user', '_user'
|
|
keystore 'xpack.notification.email.account._email.smtp.secure_password', '_passwd'
|
|
setting 'xpack.license.self_generated.type', 'trial'
|
|
extraConfigFile 'roles.yml', file('roles.yml')
|
|
user username: "test_admin", password: "x-pack-test-password"
|
|
user username: "x_pack_rest_user", password: "x-pack-test-password", role: "watcher_manager"
|
|
user username: "watcher_manager", password: "x-pack-test-password", role: "watcher_manager"
|
|
user username: "powerless_user", password: "x-pack-test-password", role: "crappy_role"
|
|
}
|