mirror of
https://github.com/elastic/kibana.git
synced 2025-04-23 09:19:04 -04:00
fix Failing test: X-Pack Saved Object Tagging Functional Tests.x-pack/test/saved_object_tagging/functional/tests/dashboard_integration·ts - saved objects tagging - functional tests dashboard integration creating allows to select tags for a new dashboard (#160687)
Closes https://github.com/elastic/kibana/issues/160583 flaky test runner https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/2513 Harden `dashboard_page.enterDashboardTitleAndClickSave` for retry loops so does not try to open save dialog when its already open from first save attempt failure. --------- Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
This commit is contained in:
parent
27b82d9995
commit
ef7fda2d24
1 changed files with 7 additions and 6 deletions
|
@ -472,11 +472,10 @@ export class DashboardPageObject extends FtrService {
|
|||
*/
|
||||
public async saveDashboard(
|
||||
dashboardName: string,
|
||||
saveOptions: SaveDashboardOptions = { waitDialogIsClosed: true, exitFromEditMode: true },
|
||||
clickMenuItem = true
|
||||
saveOptions: SaveDashboardOptions = { waitDialogIsClosed: true, exitFromEditMode: true }
|
||||
) {
|
||||
await this.retry.try(async () => {
|
||||
await this.enterDashboardTitleAndClickSave(dashboardName, saveOptions, clickMenuItem);
|
||||
await this.enterDashboardTitleAndClickSave(dashboardName, saveOptions);
|
||||
|
||||
if (saveOptions.needsConfirm) {
|
||||
await this.ensureDuplicateTitleCallout();
|
||||
|
@ -516,10 +515,12 @@ export class DashboardPageObject extends FtrService {
|
|||
*/
|
||||
public async enterDashboardTitleAndClickSave(
|
||||
dashboardTitle: string,
|
||||
saveOptions: SaveDashboardOptions = { waitDialogIsClosed: true },
|
||||
clickMenuItem = true
|
||||
saveOptions: SaveDashboardOptions = { waitDialogIsClosed: true }
|
||||
) {
|
||||
if (clickMenuItem) {
|
||||
const isSaveModalOpen = await this.testSubjects.exists('savedObjectSaveModal', {
|
||||
timeout: 2000,
|
||||
});
|
||||
if (!isSaveModalOpen) {
|
||||
await this.testSubjects.click('dashboardSaveMenuItem');
|
||||
}
|
||||
const modalDialog = await this.testSubjects.find('savedObjectSaveModal');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue