Improve Gateway authentication and static HTTP fidelity
This commit is contained in:
1 parent
42561bfa34
commit
4ab9411aca
8 files changed
+167
-58
No files matched your search
+1
-1
@@ -101,7 +101,7 @@ def main():
|
||||
wire_digest = hashlib.sha256(raw).hexdigest()
|
||||
# Wait for finally-recorded evidence after the response has closed.
|
||||
assert (pathlib.Path(workspace.name) / 'artifacts' / (wire_digest + '.bin')).read_bytes() == raw
|
||||
assert b'200' in raw_request(b'CUSTOM / HTTP/1.1\r\nHost: localhost\r\nConnection: close\r\n\r\n').split(b'\r\n')[0]
|
||||
assert b'405' in raw_request(b'CUSTOM / HTTP/1.1\r\nHost: localhost\r\nConnection: close\r\n\r\n').split(b'\r\n')[0]
|
||||
assert b'400' in raw_request(b'not-http\r\n')
|
||||
partial = b'PUT / HTTP/1.1\r\nHost: localhost\r\nContent-Length: 10\r\n\r\nabc'
|
||||
assert b'400' in raw_request(partial)
|
||||
|
||||
Reference in new issue
Block a user