Skip to content

Commit

Permalink
test: make "remove header" test actually test be havior (#4092)
Browse files Browse the repository at this point in the history
  • Loading branch information
yury-s authored Oct 15, 2020
1 parent 3c32c16 commit 180aa01
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/page-route.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ it('should be able to remove headers', async ({page, server}) => {
await page.route('**/*', route => {
const headers = Object.assign({}, route.request().headers(), {
foo: 'bar',
origin: undefined, // remove "origin" header
accept: undefined, // remove "accept" header
});
route.continue({ headers });
});
Expand All @@ -110,7 +110,7 @@ it('should be able to remove headers', async ({page, server}) => {
page.goto(server.PREFIX + '/empty.html')
]);

expect(serverRequest.headers.origin).toBe(undefined);
expect(serverRequest.headers.accept).toBe(undefined);
});

it('should contain referer header', async ({page, server}) => {
Expand Down

0 comments on commit 180aa01

Please sign in to comment.