MCPcopy
hub / github.com/scrapy/scrapy / test_cookies_dict

Method test_cookies_dict

tests/test_utils_request.py:361–372  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

359 self._test_request(request_object, expected_curl_command)
360
361 def test_cookies_dict(self):
362 request_object = Request(
363 "https://www.httpbin.org/post",
364 method="POST",
365 cookies={"foo": "bar"},
366 body=json.dumps({"foo": "bar"}),
367 )
368 expected_curl_command = (
369 "curl -X POST https://www.httpbin.org/post"
370 " --data-raw '{\"foo\": \"bar\"}' --cookie 'foo=bar'"
371 )
372 self._test_request(request_object, expected_curl_command)
373
374 def test_cookies_list(self):
375 request_object = Request(

Callers

nothing calls this directly

Calls 2

_test_requestMethod · 0.95
RequestClass · 0.90

Tested by

no test coverage detected