From 5954a8e16a64a369072a7487f62b6396a451ae5f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?No=C3=83=C2=A9mi=20V=C3=83=C2=A1nyi?= Date: Wed, 1 Nov 2017 16:50:27 +0100 Subject: minor fix of BASE engine --- tests/unit/engines/test_base.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'tests/unit/engines/test_base.py') diff --git a/tests/unit/engines/test_base.py b/tests/unit/engines/test_base.py index e008b034c..b5da5bde7 100644 --- a/tests/unit/engines/test_base.py +++ b/tests/unit/engines/test_base.py @@ -21,10 +21,10 @@ class TestBaseEngine(SearxTestCase): self.assertRaises(AttributeError, base.response, '') self.assertRaises(AttributeError, base.response, '[]') - response = mock.Mock(text='') + response = mock.Mock(content=b'') self.assertEqual(base.response(response), []) - xml_mock = """ + xml_mock = b""" 0 @@ -83,7 +83,7 @@ class TestBaseEngine(SearxTestCase): """ - response = mock.Mock(text=xml_mock.encode('utf-8')) + response = mock.Mock(content=xml_mock) results = base.response(response) self.assertEqual(type(results), list) self.assertEqual(len(results), 1) -- cgit v1.2.3