-
Notifications
You must be signed in to change notification settings - Fork 24.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SQL: Use new testing framework #101774
Merged
alex-spies
merged 19 commits into
elastic:main
from
alex-spies:sql-new-testing-framework
Nov 14, 2023
Merged
SQL: Use new testing framework #101774
Changes from 18 commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
5f68d8d
Switch RestSqlIT to new framework
alex-spies 87ddc78
Enable freeze plugin as before
alex-spies 93f67aa
Make CliErrorsIT work for single-node
alex-spies 9c5964f
Make all single node IT run with new framework
alex-spies b0f4e60
Refactor SqlSecurityTestCase
alex-spies b4ec6b1
Remove obsolete setting for single node tests
alex-spies fe4affc
Move multi-node ITs to new framework
alex-spies 9bf3cd4
Attempt remote cluster setup with new framework
alex-spies 6a873f4
Properly close remote client
alex-spies 44773e8
Refactor
alex-spies f494676
Remove obsolete gradle cluster conf
alex-spies 09cb6b4
Make JdbcCatalogIT work
alex-spies 342c144
Refactor
alex-spies 9f9350b
Make JdbcCsvSpecIT and JdbcMetadataIT work
alex-spies 0d7e9d0
Merge remote-tracking branch 'upstream/main' into sql-new-testing-fra…
alex-spies 0de17ae
Cleanup
alex-spies 5f6fdde
Spotless
alex-spies 724a708
Fix gradle config for Security tests
alex-spies 366df74
Remove leftover comment
alex-spies File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
52 changes: 1 addition & 51 deletions
52
x-pack/plugin/sql/qa/server/multi-cluster-with-security/build.gradle
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,56 +1,6 @@ | ||
import org.elasticsearch.gradle.testclusters.DefaultTestClustersTask | ||
import static org.elasticsearch.gradle.PropertyNormalization.IGNORE_VALUE | ||
|
||
apply plugin: 'elasticsearch.legacy-java-rest-test' | ||
|
||
dependencies { | ||
javaRestTestImplementation project(path: xpackModule('ql:test-fixtures')) | ||
clusterPlugins project(':x-pack:qa:freeze-plugin') | ||
} | ||
|
||
def remoteClusterReg = testClusters.register('remote-cluster') { | ||
testDistribution = 'DEFAULT' | ||
setting 'node.roles', '[data,ingest,master]' | ||
setting 'xpack.ml.enabled', 'false' | ||
setting 'xpack.watcher.enabled', 'false' | ||
setting 'xpack.security.enabled', 'true' | ||
setting 'xpack.license.self_generated.type', 'trial' | ||
setting 'xpack.security.autoconfiguration.enabled', 'false' | ||
|
||
user username: "test_user", password: "x-pack-test-password" | ||
plugin ':x-pack:qa:freeze-plugin' | ||
} | ||
|
||
def javaRestTestClusterReg = testClusters.register('javaRestTest') { | ||
testDistribution = 'DEFAULT' | ||
setting 'xpack.ml.enabled', 'false' | ||
setting 'xpack.watcher.enabled', 'false' | ||
setting 'cluster.remote.my_remote_cluster.seeds', { | ||
remoteClusterReg.get().getAllTransportPortURI().collect { "\"$it\"" }.toString() | ||
}, IGNORE_VALUE | ||
setting 'cluster.remote.connections_per_cluster', "1" | ||
setting 'xpack.security.enabled', 'true' | ||
setting 'xpack.license.self_generated.type', 'trial' | ||
setting 'xpack.security.autoconfiguration.enabled', 'false' | ||
|
||
user username: "test_user", password: "x-pack-test-password" | ||
plugin ':x-pack:qa:freeze-plugin' | ||
} | ||
|
||
tasks.register("startRemoteCluster", DefaultTestClustersTask.class) { | ||
useCluster remoteClusterReg | ||
doLast { | ||
"Starting remote cluster before integ tests and integ test cluster is started" | ||
} | ||
} | ||
|
||
tasks.named("javaRestTest").configure { | ||
dependsOn 'startRemoteCluster' | ||
useCluster remoteClusterReg | ||
doFirst { | ||
nonInputProperties.systemProperty 'tests.rest.cluster.remote.host', remoteClusterReg.map(c->c.getAllHttpSocketURI().get(0)) | ||
// credentials for both local and remote clusters | ||
nonInputProperties.systemProperty 'tests.rest.cluster.multi.user', "test_user" | ||
nonInputProperties.systemProperty 'tests.rest.cluster.multi.password', "x-pack-test-password" | ||
} | ||
} | ||
tasks.named("check").configure {dependsOn("javaRestTest") } // run these tests as part of the "check" task |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nothing below this line is new - only fixed indentation (was tripping me up, haha).