Skip to content

Commit bab5716

Browse files
authored
fix: Flaky AppLayout error boundaries tests (#4402)
1 parent 7364de0 commit bab5716

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

src/app-layout/__integ__/app-layout-error-boundaries.test.ts

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,10 @@ describe('Visual refresh toolbar only', () => {
6767
`should handle error boundary in ${areaName}`,
6868
setupTest({ hasParentErrorBoundary: 'true' }, async page => {
6969
await page.click(selector);
70-
await page.expectConsoleErrors();
71-
await page.expectContentAreaStaysFunctional();
70+
await page.waitForAssertion(async () => {
71+
await page.expectConsoleErrors();
72+
await page.expectContentAreaStaysFunctional();
73+
});
7274
})
7375
);
7476
});
@@ -80,8 +82,10 @@ describe('Visual refresh toolbar only', () => {
8082
`should handle error boundary in ${areaName}`,
8183
setupTest({ hasParentErrorBoundary: 'false' }, async page => {
8284
await page.click(selector);
83-
await page.expectConsoleErrors();
84-
await page.expectContentAreaStaysFunctional();
85+
await page.waitForAssertion(async () => {
86+
await page.expectConsoleErrors();
87+
await page.expectContentAreaStaysFunctional();
88+
});
8589
})
8690
);
8791
});

0 commit comments

Comments
 (0)