def test_assert_header_parsing_no_error_on_multipart(self): from http import client header_msg = io.BytesIO() header_msg.write( b'Content-Type: multipart/encrypted;protocol="application/' b'HTTP-SPNEGO-session-encrypted";boundary="Encrypted Boundary"' b"\nServer: Microsoft-HTTPAPI/2.0\nDate: Fri, 16 Aug 2019 19:28:01 GMT" b"\nContent-Length: 1895\n\n\n") header_msg.seek(0) assert_header_parsing(client.parse_headers(header_msg))
def test_assert_header_parsing_throws_typeerror_with_non_headers(self, headers): with pytest.raises(TypeError): assert_header_parsing(headers)
def test_assert_header_parsing_throws_typeerror_with_non_headers( self, headers): with pytest.raises(TypeError): assert_header_parsing(headers)
def test_assert_header_parsing_throws_typeerror_with_non_headers( self, headers: Optional[Union[bytes, object]]) -> None: with pytest.raises(TypeError): assert_header_parsing(headers) # type: ignore[arg-type]