Skip to content

Commit

Permalink
test: verify overriding postdata and method on navigation (#4317)
Browse files Browse the repository at this point in the history
References #4309
  • Loading branch information
aslushnikov committed Apr 20, 2019
1 parent e3abb0a commit 770411b
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions test/requestinterception.spec.js
Expand Up @@ -424,6 +424,18 @@ module.exports.addTests = function({testRunner, expect, CHROME}) {
]);
expect(await serverRequest.postBody).toBe('doggo');
});
it_fails_ffox('should amend both post data and method on navigation', async({page, server}) => {
await page.setRequestInterception(true);
page.on('request', request => {
request.continue({ method: 'POST', postData: 'doggo' });
});
const [serverRequest] = await Promise.all([
server.waitForRequest('/empty.html'),
page.goto(server.EMPTY_PAGE),
]);
expect(serverRequest.method).toBe('POST');
expect(await serverRequest.postBody).toBe('doggo');
});
});

describe_fails_ffox('Request.respond', function() {
Expand Down

0 comments on commit 770411b

Please sign in to comment.