Skip to content

Commit 3287b4c

Browse files
authored
chore(e2e): wait for the bulk update toast text (#7562)
wait for the bulk update toast text
1 parent 50adb49 commit 3287b4c

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

packages/compass-e2e-tests/tests/collection-bulk-update.test.ts

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -112,11 +112,13 @@ describe('Bulk Update', () => {
112112
// The success toast is displayed
113113
await browser.$(Selectors.BulkUpdateSuccessToast).waitForDisplayed();
114114

115-
const toastText = await browser
116-
.$(Selectors.BulkUpdateSuccessToast)
117-
.getText();
115+
await browser.waitUntil(async () => {
116+
const toastText = await browser
117+
.$(Selectors.BulkUpdateSuccessToast)
118+
.getText();
119+
return toastText.includes('1 document has been updated.');
120+
});
118121

119-
expect(toastText).to.contain('1 document has been updated.');
120122
// We close the toast
121123
await browser.clickVisible(Selectors.BulkUpdateSuccessToastDismissButton);
122124

0 commit comments

Comments
 (0)