test: enable header overrides on redirect in firefox (#32088)
Fixes: https://github.com/microsoft/playwright/issues/32045
This commit is contained in:
parent
5cc1e7b299
commit
236a8ac2ac
|
|
@ -393,9 +393,12 @@ it('should continue preload link requests', async ({ page, server, browserName }
|
||||||
expect(color).toBe('rgb(255, 192, 203)');
|
expect(color).toBe('rgb(255, 192, 203)');
|
||||||
});
|
});
|
||||||
|
|
||||||
it('continue should propagate headers to redirects', async ({ page, server, browserName }) => {
|
it('continue should propagate headers to redirects', {
|
||||||
it.info().annotations.push({ type: 'issue', description: 'https://github.com/microsoft/playwright/issues/28758' });
|
annotation: [
|
||||||
it.fixme(browserName === 'firefox');
|
{ type: 'issue', description: 'https://github.com/microsoft/playwright/issues/28758' },
|
||||||
|
{ type: 'issue', description: 'https://github.com/microsoft/playwright/issues/32045' },
|
||||||
|
]
|
||||||
|
}, async ({ page, server }) => {
|
||||||
await server.setRedirect('/redirect', '/empty.html');
|
await server.setRedirect('/redirect', '/empty.html');
|
||||||
await page.route('**/redirect', route => {
|
await page.route('**/redirect', route => {
|
||||||
void route.continue({
|
void route.continue({
|
||||||
|
|
@ -413,9 +416,11 @@ it('continue should propagate headers to redirects', async ({ page, server, brow
|
||||||
});
|
});
|
||||||
|
|
||||||
it('redirected requests should report overridden headers', {
|
it('redirected requests should report overridden headers', {
|
||||||
annotation: { type: 'issue', description: 'https://github.com/microsoft/playwright/issues/31351' }
|
annotation: [
|
||||||
}, async ({ page, server, browserName }) => {
|
{ type: 'issue', description: 'https://github.com/microsoft/playwright/issues/31351' },
|
||||||
it.fixme(browserName === 'firefox');
|
{ type: 'issue', description: 'https://github.com/microsoft/playwright/issues/32045' },
|
||||||
|
]
|
||||||
|
}, async ({ page, server }) => {
|
||||||
await server.setRedirect('/redirect', '/empty.html');
|
await server.setRedirect('/redirect', '/empty.html');
|
||||||
await page.route('**/redirect', route => {
|
await page.route('**/redirect', route => {
|
||||||
const headers = route.request().headers();
|
const headers = route.request().headers();
|
||||||
|
|
@ -433,9 +438,12 @@ it('redirected requests should report overridden headers', {
|
||||||
expect((await response.request().allHeaders())['custom']).toBe('value');
|
expect((await response.request().allHeaders())['custom']).toBe('value');
|
||||||
});
|
});
|
||||||
|
|
||||||
it('continue should delete headers on redirects', async ({ page, server, browserName }) => {
|
it('continue should delete headers on redirects', {
|
||||||
it.info().annotations.push({ type: 'issue', description: 'https://github.com/microsoft/playwright/issues/13106' });
|
annotation: [
|
||||||
it.fixme(browserName === 'firefox');
|
{ type: 'issue', description: 'https://github.com/microsoft/playwright/issues/13106' },
|
||||||
|
{ type: 'issue', description: 'https://github.com/microsoft/playwright/issues/32045' },
|
||||||
|
]
|
||||||
|
}, async ({ page, server }) => {
|
||||||
await page.goto(server.PREFIX + '/empty.html');
|
await page.goto(server.PREFIX + '/empty.html');
|
||||||
server.setRoute('/something', (request, response) => {
|
server.setRoute('/something', (request, response) => {
|
||||||
response.writeHead(200, { 'Access-Control-Allow-Origin': '*' });
|
response.writeHead(200, { 'Access-Control-Allow-Origin': '*' });
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue