-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[Data Discovery] Run example plugin functional tests in Serverless #163411
[Data Discovery] Run example plugin functional tests in Serverless #163411
Conversation
26184a2
to
0ffdb5e
Compare
"type": "doc", | ||
"value": { | ||
"id": "index-pattern:histogram-test", | ||
"index": ".kibana_analytics_1", |
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.
When running Serverless functional tests, the index used for data view SOs is .kibana_analytics_1
instead of .kibana_analytics
as in stateful, so I copied and modified this file to reflect that.
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.
We try to avoid the usage of system indices in esArchives where possible (outside of specific SO migration tests, this often brings a lot of trouble and has been root cause of race conditions in the past). Have you considered using the kbnArchiver
to save and restore this data view? Example usage here: https://github.com/elastic/kibana/blob/main/x-pack/test/functional/apps/canvas/custom_elements.ts#L28
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.
so it seems this test should be rewritten, but this could als be a follow up PR IMO
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.
I agree, this can be done as a follow-up.
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.
Thanks for the info! I agree, let's do this work as a followup and fix it in both stateful and serverless.
Pinging @elastic/kibana-data-discovery (Team:DataDiscovery) |
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.
Great work. The only problem I see is that we won't be able to run these tests against projects created on MKI, meaning we won't verify functionality in the real customer environment.
0ffdb5e
to
5849d44
Compare
x-pack/test_serverless/functional/test_suites/examples/config.ts
Outdated
Show resolved
Hide resolved
x-pack/test_serverless/functional/test_suites/common/examples/search_examples/index.ts
Outdated
Show resolved
Hide resolved
f9e5062
to
a1e5b61
Compare
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.
x-pack/test_serverless/functional/test_suites/common/examples/search_examples/index.ts
Outdated
Show resolved
Hide resolved
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.
CI changes lgtm
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.
DataDiscovery.lgtm Code review, in buildkites testing abilities we trust 👍
a03cf41
to
ddb9057
Compare
I believe we should hold on with this PR until #162673 is merged. Then pull the latest main with actual serverless ES and make sure these tests are still passing. |
8d653f5
to
88679b4
Compare
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.
LGTM
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.
LGTM
💚 Build Succeeded
Metrics [docs]
History
To update your PR or re-run it, just comment with: cc @davismcphee |
Summary
Important
These tests currently do not run in "real" Serverless and only run in "local" Serverless (what we use in CI). Additional work will need to be done to allow these tests to be run in an actual Serverless environment, since they required
config.ts
changes which are only loaded when running locally.This PR copies the Data Discovery example plugin functional tests to
test_serverless
and adds support for running them against the Search project.It also adds support for running functional tests against example plugins in general in Serverless ("local" Serverless only currently).
In the future these should run as deployment-agnostic tests, but support does not yet exist (see #161574), so in the meantime they've been duplicated and modified in place. I've left
TODO
comments where test files have been modified so we know what needs to be addressed once they are converted to deployment-agnostic tests.Part of #162347.
Checklist
Any text added follows EUI's writing guidelines, uses sentence case text and includes i18n supportDocumentation was added for features that require explanation or tutorialsAny UI touched in this PR is usable by keyboard only (learn more about keyboard accessibility)Any UI touched in this PR does not create any new axe failures (run axe in browser: FF, Chrome)If a plugin configuration key changed, check if it needs to be allowlisted in the cloud and added to the docker listThis renders correctly on smaller devices using a responsive layout. (You can test this in your browser)This was checked for cross-browser compatibilityFor maintainers