Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions tests/async/test_defaultbrowsercontext.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ async def test_context_add_cookies_should_work(
]
)
assert await page.evaluate("() => document.cookie") == "username=John Doe"
assert await page.context.cookies() == [
assert _filter_cookies(await page.context.cookies()) == [
{
"name": "username",
"value": "John Doe",
Expand All @@ -127,7 +127,7 @@ async def test_context_add_cookies_should_work(

def _filter_cookies(cookies: Sequence[Cookie]) -> List[Cookie]:
return list(
filter(lambda cookie: cookie["domain"] != "copilot.microsoft.com", cookies)
filter(lambda cookie: not cookie["domain"].endswith("microsoft.com"), cookies)
)


Expand Down
Loading