summaryrefslogtreecommitdiffhomepage
path: root/test/unit
diff options
context:
space:
mode:
Diffstat (limited to 'test/unit')
-rw-r--r--test/unit/check/njs.py6
-rw-r--r--test/unit/http.py4
2 files changed, 9 insertions, 1 deletions
diff --git a/test/unit/check/njs.py b/test/unit/check/njs.py
new file mode 100644
index 00000000..433473a1
--- /dev/null
+++ b/test/unit/check/njs.py
@@ -0,0 +1,6 @@
+import re
+
+
+def check_njs(output_version):
+ if re.search('--njs', output_version):
+ return True
diff --git a/test/unit/http.py b/test/unit/http.py
index 144f300c..c48a720f 100644
--- a/test/unit/http.py
+++ b/test/unit/http.py
@@ -102,7 +102,9 @@ class TestHTTP:
if 'read_buffer_size' in kwargs:
recvall_kwargs['buff_size'] = kwargs['read_buffer_size']
- resp = self.recvall(sock, **recvall_kwargs).decode(encoding)
+ resp = self.recvall(sock, **recvall_kwargs).decode(
+ encoding, errors='ignore'
+ )
else:
return sock