Skip to content

Commit b10e092

Browse files
ndelangenshilman
authored andcommitted
Merge pull request #22022 from storybookjs/fix-e2e-tests
Fix e2e tests failing in Firefox
1 parent 2fc71ea commit b10e092

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

code/e2e-tests/util.ts

+3-2
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,9 @@ export class SbPage {
3737
// assert url changes
3838
const viewMode = name === 'docs' ? 'docs' : 'story';
3939

40-
const url = this.page.url();
41-
await expect(url).toContain(`path=/${viewMode}/${titleId}--${storyId}`);
40+
await this.page.waitForURL((url) =>
41+
url.search.includes(`path=/${viewMode}/${titleId}--${storyId}`)
42+
);
4243

4344
const selected = await storyLink.getAttribute('data-selected');
4445
await expect(selected).toBe('true');

0 commit comments

Comments
 (0)