MCPcopy
hub / github.com/psf/requests / test_different_encodings_dont_break_post

Method test_different_encodings_dont_break_post

tests/test_requests.py:1080–1088  ·  view source on GitHub ↗
(self, httpbin)

Source from the content-addressed store, hash-verified

1078 assert prep.body == "test=foo&test=baz"
1079
1080 def test_different_encodings_dont_break_post(self, httpbin):
1081 with open(__file__, "rb") as f:
1082 r = requests.post(
1083 httpbin("post"),
1084 data={"stuff": json.dumps({"a": 123})},
1085 params={"blah": "asdf1234"},
1086 files={"file": ("test_requests.py", f)},
1087 )
1088 assert r.status_code == 200
1089
1090 @pytest.mark.parametrize(
1091 "data",

Callers

nothing calls this directly

Calls 2

httpbinFunction · 0.85
postMethod · 0.80

Tested by

no test coverage detected