From f829942d4e18c849075433f70f98209ea8465447 Mon Sep 17 00:00:00 2001 From: Nathan Reese Date: Wed, 8 Mar 2023 14:54:05 -0700 Subject: [PATCH] =?UTF-8?q?[dashboard]=20fix=20Failing=20test:=20Chrome=20?= =?UTF-8?q?X-Pack=20UI=20Functional=20Tests.x-pack/test/functional/apps/da?= =?UTF-8?q?shboard/group2/sync=5Fcolors=C2=B7ts=20(#152964)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixes https://github.com/elastic/kibana/issues/148557 flaky test runner https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/2000 Image from failed test shows query autosuggest menu is blocking "create visualize" button. PR fixes issue be pressing escape to close autosuggest menu if its open. ![image](https://user-images.githubusercontent.com/373691/223846637-3e595803-e39d-4392-a84c-69a455f70a42.png) --- test/functional/services/dashboard/add_panel.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/functional/services/dashboard/add_panel.ts b/test/functional/services/dashboard/add_panel.ts index 7af97ef7ff32f..c68b6deb46953 100644 --- a/test/functional/services/dashboard/add_panel.ts +++ b/test/functional/services/dashboard/add_panel.ts @@ -15,6 +15,7 @@ export class DashboardAddPanelService extends FtrService { private readonly common = this.ctx.getPageObject('common'); private readonly header = this.ctx.getPageObject('header'); private readonly savedObjectsFinder = this.ctx.getService('savedObjectsFinder'); + private readonly browser = this.ctx.getService('browser'); async clickOpenAddPanel() { this.log.debug('DashboardAddPanel.clickOpenAddPanel'); @@ -26,6 +27,8 @@ export class DashboardAddPanelService extends FtrService { async clickCreateNewLink() { this.log.debug('DashboardAddPanel.clickAddNewPanelButton'); await this.retry.try(async () => { + // prevent query bar auto suggest from blocking button + await this.browser.pressKeys(this.browser.keys.ESCAPE); await this.testSubjects.click('dashboardAddNewPanelButton'); await this.testSubjects.waitForDeleted('dashboardAddNewPanelButton'); await this.header.waitUntilLoadingHasFinished();