mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
test: fix some ff cookie tests (#12039)
This commit is contained in:
parent
2ef161be3c
commit
43f2453823
@ -1215,13 +1215,6 @@
|
||||
"expectations": ["FAIL", "PASS"],
|
||||
"comment": "TODO: add a comment explaining why this expectation is required (include links to issues)"
|
||||
},
|
||||
{
|
||||
"testIdPattern": "[cookies.spec] Cookie specs Page.cookies should get cookies from multiple urls",
|
||||
"platforms": ["darwin", "linux", "win32"],
|
||||
"parameters": ["firefox", "webDriverBiDi"],
|
||||
"expectations": ["FAIL"],
|
||||
"comment": "TODO: add a comment explaining why this expectation is required (include links to issues)"
|
||||
},
|
||||
{
|
||||
"testIdPattern": "[cookies.spec] Cookie specs Page.cookies should get cookies from nested path",
|
||||
"platforms": ["darwin", "linux", "win32"],
|
||||
@ -1296,8 +1289,8 @@
|
||||
"testIdPattern": "[cookies.spec] Cookie specs Page.setCookie should default to setting secure cookie for HTTPS websites",
|
||||
"platforms": ["darwin", "linux", "win32"],
|
||||
"parameters": ["firefox", "webDriverBiDi"],
|
||||
"expectations": ["FAIL"],
|
||||
"comment": "TODO: add a comment explaining why this expectation is required (include links to issues)"
|
||||
"expectations": ["SKIP"],
|
||||
"comment": "Chromium-specific test. The test relies on the cookie in secure context to be secure. This is not the case for Firefox."
|
||||
},
|
||||
{
|
||||
"testIdPattern": "[cookies.spec] Cookie specs Page.setCookie should isolate cookies in browser contexts",
|
||||
@ -1373,8 +1366,8 @@
|
||||
"testIdPattern": "[cookies.spec] Cookie specs Page.setCookie should set secure same-site cookies from a frame",
|
||||
"platforms": ["darwin", "linux", "win32"],
|
||||
"parameters": ["firefox", "webDriverBiDi"],
|
||||
"expectations": ["FAIL"],
|
||||
"comment": "TODO: add a comment explaining why this expectation is required (include links to issues)"
|
||||
"expectations": ["SKIP"],
|
||||
"comment": "Chromium-specific test. The test relies on the cookie in secure context to be secure. This is not the case for Firefox."
|
||||
},
|
||||
{
|
||||
"testIdPattern": "[cookies.spec] Cookie specs Page.setCookie should work",
|
||||
|
@ -150,7 +150,6 @@ describe('Cookie specs', () => {
|
||||
expires: -1,
|
||||
size: 11,
|
||||
httpOnly: false,
|
||||
secure: true,
|
||||
session: true,
|
||||
sourceScheme: 'Secure',
|
||||
},
|
||||
@ -163,7 +162,6 @@ describe('Cookie specs', () => {
|
||||
expires: -1,
|
||||
size: 10,
|
||||
httpOnly: false,
|
||||
secure: true,
|
||||
session: true,
|
||||
sourceScheme: 'Secure',
|
||||
},
|
||||
@ -436,7 +434,6 @@ describe('Cookie specs', () => {
|
||||
expires: -1,
|
||||
size: 18,
|
||||
httpOnly: false,
|
||||
secure: true,
|
||||
session: true,
|
||||
sourceScheme: 'Secure',
|
||||
},
|
||||
|
@ -378,17 +378,21 @@ export const expectCookieEquals = async (
|
||||
if (!processVariables.isChrome) {
|
||||
// Only keep standard properties when testing on a browser other than Chrome.
|
||||
expectedCookies = expectedCookies.map(cookie => {
|
||||
return {
|
||||
domain: cookie.domain,
|
||||
expires: cookie.expires,
|
||||
httpOnly: cookie.httpOnly,
|
||||
name: cookie.name,
|
||||
path: cookie.path,
|
||||
secure: cookie.secure,
|
||||
session: cookie.session,
|
||||
size: cookie.size,
|
||||
value: cookie.value,
|
||||
};
|
||||
return Object.fromEntries(
|
||||
Object.entries(cookie).filter(([key]) => {
|
||||
return [
|
||||
'domain',
|
||||
'expires',
|
||||
'httpOnly',
|
||||
'name',
|
||||
'path',
|
||||
'secure',
|
||||
'session',
|
||||
'size',
|
||||
'value',
|
||||
].includes(key);
|
||||
})
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user