mirror of
https://github.com/microsoft/playwright.git
synced 2025-06-26 21:40:17 +00:00
test(webkit): expect cookies to be deleted after reload
This commit is contained in:
parent
d542ef849f
commit
a9b7bcf905
@ -465,7 +465,7 @@ module.exports.describe = function({testRunner, expect, playwright, defaultBrows
|
||||
});
|
||||
|
||||
describe('BrowserContext.clearCookies', function() {
|
||||
it.fail(WEBKIT)('should clear cookies', async({context, page, server}) => {
|
||||
it('should clear cookies', async({context, page, server}) => {
|
||||
await page.goto(server.EMPTY_PAGE);
|
||||
await context.setCookies([{
|
||||
url: server.EMPTY_PAGE,
|
||||
@ -474,6 +474,8 @@ module.exports.describe = function({testRunner, expect, playwright, defaultBrows
|
||||
}]);
|
||||
expect(await page.evaluate('document.cookie')).toBe('cookie1=1');
|
||||
await context.clearCookies();
|
||||
expect(await context.cookies()).toEqual([]);
|
||||
await page.reload();
|
||||
expect(await page.evaluate('document.cookie')).toBe('');
|
||||
});
|
||||
it('should isolate cookies when clearing', async({context, server, browser}) => {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user