*) test: improved nghttp client output parsing.
@@ -80,6 +80,7 @@ class Nghttp:
# chunk output into lines. nghttp mixes text
# meta output with bytes from the response body.
lines = [l.decode() for l in btext.split(b'\n')]
+
for lidx, l in enumerate(lines):
if len(l) == 0:
body += '\n'
@@ -96,7 +97,6 @@ class Nghttp:
header[hname] += ", %s" % hval
else:
header[hname] = hval
- body = ''
continue
m = re.match(r'(.*)\[.*] recv HEADERS frame <.* stream_id=(\d+)>', l)
@@ -120,7 +120,6 @@ class Nghttp:
response["previous"] = prev
response[hkey] = s["header"]
s["header"] = {}
- body = ''
continue
m = re.match(r'(.*)\[.*] recv DATA frame <length=(\d+), .*stream_id=(\d+)>', l)
