Skip to content

Commit 424f62a

Browse files
committed
test(segment-view): wait for image to load
1 parent 42e44ad commit 424f62a

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

core/src/components/segment-view/test/dynamic-height/segment-view.e2e.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,13 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
5959
// Wait for the content to be scrolled
6060
await page.waitForChanges();
6161

62+
// Wait for the image to load and be visible
63+
const imgLocator = page.locator('ion-segment-content#third ion-img');
64+
await imgLocator.waitFor({ state: 'visible', timeout: 10000 });
65+
66+
// Wait for any layout adjustments
67+
await page.waitForChanges();
68+
6269
// Check that the third content is visible
6370
const segmentView = page.locator('ion-segment-view');
6471
const thirdContent = page.locator('ion-segment-content#third');

0 commit comments

Comments
 (0)