Skip to content

Commit

Permalink
test(webkit): expect cookies to be deleted after reload
Browse files Browse the repository at this point in the history
  • Loading branch information
pavelfeldman committed Mar 10, 2020
1 parent d542ef8 commit a9b7bcf
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test/cookies.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand All @@ -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}) => {
Expand Down

0 comments on commit a9b7bcf

Please sign in to comment.