Skip to content

[Discover] Fix time zone switch functional test in cloud env#76396

Merged
kertal merged 2 commits intoelastic:masterfrom
kertal:kertal-pr-2020-09-01-discover-fix-functional-test-timezone-switch
Sep 4, 2020
Merged

[Discover] Fix time zone switch functional test in cloud env#76396
kertal merged 2 commits intoelastic:masterfrom
kertal:kertal-pr-2020-09-01-discover-fix-functional-test-timezone-switch

Conversation

@kertal
Copy link
Copy Markdown
Member

@kertal kertal commented Sep 1, 2020

Summary

The overlapping of the query bar with the index pattern selector caused a test fail in cloud. Setting the query bar to '' triggered displaying suggestions, overlapping the index pattern selector. So this PR adds a new function to clear the query, which is followed by a TAB to move focus to the next tabbable element.

image

Here's the test run to prove that it no longer fails:
https://internal-ci.elastic.co/job/elastic+estf-cloud-kibana-flaky-test-runner/105/

Fixes #76166

Checklist

@kertal kertal self-assigned this Sep 1, 2020
@kertal kertal added Feature:Discover Discover Application Team:Visualizations Team label for Lens, elastic-charts, Graph, legacy editors (TSVB, Visualize, Timelion) t// v7.10.0 v8.0.0 release_note:skip Skip the PR/issue when compiling release notes labels Sep 1, 2020
@kertal kertal marked this pull request as ready for review September 1, 2020 17:41
@elasticmachine
Copy link
Copy Markdown
Contributor

Pinging @elastic/kibana-app (Team:KibanaApp)


// Pause the browser at a certain place for debugging
// Not meant for usage in CI, only for dev-usage
async pause() {
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is now completely off topic, but I was just excited to find a pause function for the functional tests 🥳


public async clearQuery(): Promise<void> {
await this.setQuery('');
await PageObjects.common.pressTabKey();
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

moving focus by tab closes the query bar suggestions, also the time picker is then displayed again, which simplifies the code of the failing Discover test

@kertal kertal changed the title [Discover] Improve query reset to prevent cloud flakiness [Discover] Fix time zone switch functional test in cloud env Sep 2, 2020
@kertal
Copy link
Copy Markdown
Member Author

kertal commented Sep 3, 2020

@elasticmachine merge upstream

@kibanamachine
Copy link
Copy Markdown
Contributor

💚 Build Succeeded

Build metrics

✅ unchanged

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

Copy link
Copy Markdown
Contributor

@dmlemeshko dmlemeshko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Feature:Discover Discover Application release_note:skip Skip the PR/issue when compiling release notes Team:Visualizations Team label for Lens, elastic-charts, Graph, legacy editors (TSVB, Visualize, Timelion) t// v7.10.0 v8.0.0

Projects

None yet

4 participants