MCPcopy
hub / github.com/encode/httpx / test_cookies_with_domain_and_path

Function test_cookies_with_domain_and_path

tests/models/test_cookies.py:45–52  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

43
44
45def test_cookies_with_domain_and_path():
46 cookies = httpx.Cookies()
47 cookies.set("name", "value", domain="example.com", path="/subpath/1")
48 cookies.set("name", "value", domain="example.com", path="/subpath/2")
49 cookies.clear(domain="example.com", path="/subpath/1")
50 assert len(cookies) == 1
51 cookies.delete("name", domain="example.com", path="/subpath/2")
52 assert len(cookies) == 0
53
54
55def test_multiple_set_cookie():

Callers

nothing calls this directly

Calls 3

setMethod · 0.95
clearMethod · 0.95
deleteMethod · 0.95

Tested by

no test coverage detected