Skip to content

Commit

Permalink
test: page.reload() on a page with a hash (#21152)
Browse files Browse the repository at this point in the history
  • Loading branch information
mxschmitt committed Feb 23, 2023
1 parent 681d584 commit 8b8444d
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tests/page/page-history.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,14 @@ it('page.reload should work with cross-origin redirect', async ({ page, server,
await expect(page).toHaveURL(server.CROSS_PROCESS_PREFIX + '/title.html');
});

it('page.reload should work on a page with a hash', async ({ page, server, browserName }) => {
it.info().annotations.push({ type: 'issue', description: 'https://github.com/microsoft/playwright/issues/21145' });
it.fixme(browserName === 'firefox');
await page.goto(server.EMPTY_PAGE + '#hash');
await page.reload();
await expect(page).toHaveURL(server.EMPTY_PAGE + '#hash');
});

it('page.goBack during renderer-initiated navigation', async ({ page, server }) => {
await page.goto(server.PREFIX + '/one-style.html');
await page.goto(server.EMPTY_PAGE);
Expand Down

0 comments on commit 8b8444d

Please sign in to comment.