Skip to content

Commit 78ea171

Browse files
Stabilize closing toast (#72097)
* stabilize closing toast * unskip test Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
1 parent b9aede4 commit 78ea171

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

test/functional/apps/dashboard/dashboard_snapshots.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,7 @@ export default function ({ getService, getPageObjects, updateBaselines }) {
2828
const dashboardPanelActions = getService('dashboardPanelActions');
2929
const dashboardAddPanel = getService('dashboardAddPanel');
3030

31-
// FLAKY: https://github.com/elastic/kibana/issues/52854
32-
describe.skip('dashboard snapshots', function describeIndexTests() {
31+
describe('dashboard snapshots', function describeIndexTests() {
3332
before(async function () {
3433
await esArchiver.load('dashboard/current/kibana');
3534
await kibanaServer.uiSettings.replace({

test/functional/page_objects/common_page.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -407,7 +407,11 @@ export function CommonPageProvider({ getService, getPageObjects }: FtrProviderCo
407407
async closeToastIfExists() {
408408
const toastShown = await find.existsByCssSelector('.euiToast');
409409
if (toastShown) {
410-
await find.clickByCssSelector('.euiToast__closeButton');
410+
try {
411+
await find.clickByCssSelector('.euiToast__closeButton');
412+
} catch (err) {
413+
// ignore errors, toast clear themselves after timeout
414+
}
411415
}
412416
}
413417

0 commit comments

Comments
 (0)