You've already forked httpie-cli
mirror of
https://github.com/httpie/cli.git
synced 2025-08-10 22:42:05 +02:00
Run tests against local httpbin instance via pytest-httpbin.
This commit is contained in:
@@ -105,8 +105,13 @@ class HTTPRequest(HTTPMessage):
|
||||
if 'Host' not in self._orig.headers:
|
||||
headers['Host'] = url.netloc.split('@')[-1]
|
||||
|
||||
headers = ['%s: %s' % (name, value)
|
||||
for name, value in headers.items()]
|
||||
headers = [
|
||||
'%s: %s' % (
|
||||
name,
|
||||
value if isinstance(value, str) else value.decode('utf8')
|
||||
)
|
||||
for name, value in headers.items()
|
||||
]
|
||||
|
||||
headers.insert(0, request_line)
|
||||
headers = '\r\n'.join(headers).strip()
|
||||
|
Reference in New Issue
Block a user