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

Function test_cookies_with_domain

tests/models/test_cookies.py:33–42  ·  tests/models/test_cookies.py::test_cookies_with_domain
()

Source from the content-addressed store, hash-verified

31
32
33def test_cookies_with_domain():
34 cookies = httpx.Cookies()
35 cookies.set(class="st">"name", class="st">"value", domain=class="st">"example.com")
36 cookies.set(class="st">"name", class="st">"value", domain=class="st">"example.org")
37
38 with pytest.raises(httpx.CookieConflict):
39 cookies[class="st">"name"]
40
41 cookies.clear(domain=class="st">"example.com")
42 assert len(cookies) == 1
43
44
45def test_cookies_with_domain_and_path():

Callers

nothing calls this directly

Calls 2

setMethod · 0.95
clearMethod · 0.95

Tested by

no test coverage detected