(self)
| 345 | self._test_request(request_object, expected_curl_command) |
| 346 | |
| 347 | def test_headers(self): |
| 348 | request_object = Request( |
| 349 | "https://www.httpbin.org/post", |
| 350 | method="POST", |
| 351 | headers={"Content-Type": "application/json", "Accept": "application/json"}, |
| 352 | body=json.dumps({"foo": "bar"}), |
| 353 | ) |
| 354 | expected_curl_command = ( |
| 355 | "curl -X POST https://www.httpbin.org/post" |
| 356 | ' --data-raw \'{"foo": "bar"}\'' |
| 357 | " -H 'Content-Type: application/json' -H 'Accept: application/json'" |
| 358 | ) |
| 359 | self._test_request(request_object, expected_curl_command) |
| 360 | |
| 361 | def test_cookies_dict(self): |
| 362 | request_object = Request( |
nothing calls this directly
no test coverage detected