Skip to content

Commit 20c4ff6

Browse files
committed
Fix HAR replay test to use correct URL from HAR file
- HAR file contains demo.playwright.dev/api-mocking URLs - Test was incorrectly trying to navigate to local test server - Updated to match HAR file content and added URL filter - Changed assertion to match actual page content
1 parent c92fe92 commit 20c4ff6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

test/helper/Playwright_test.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1966,9 +1966,9 @@ describe('Playwright - HAR', () => {
19661966

19671967
it('replay from HAR', async function () {
19681968
const harFile = './test/data/sandbox/testHar.har'
1969-
await I.replayFromHar(harFile)
1970-
await I.amOnPage('/')
1971-
await I.see('Welcome to test app')
1969+
await I.replayFromHar(harFile, { url: '*/**/api-mocking' })
1970+
await I.amOnPage('https://demo.playwright.dev/api-mocking')
1971+
await I.see('API Mocking')
19721972
})
19731973

19741974
describe('#grabWebElements, #grabWebElement', () => {

0 commit comments

Comments
 (0)