diff options
author | Adam Tauber <asciimoo@gmail.com> | 2015-12-01 15:52:20 +0100 |
---|---|---|
committer | Adam Tauber <asciimoo@gmail.com> | 2015-12-01 15:52:20 +0100 |
commit | 911ed7987cb16ed26edbf628e3657a2f2d998a36 (patch) | |
tree | b5b6306c4c918644511970a889d9b94f16aa9cb2 /searx/tests | |
parent | 786fe49fab670c3f8f8e14c6da55809ea675b9b2 (diff) | |
parent | ac8759cd3ff99024864fd04d7c4bef5c3a00b971 (diff) | |
download | searxng-911ed7987cb16ed26edbf628e3657a2f2d998a36.tar.gz searxng-911ed7987cb16ed26edbf628e3657a2f2d998a36.zip |
Merge pull request #395 from gugod/master
btdigg engine: fix text mojibake.
Diffstat (limited to 'searx/tests')
-rw-r--r-- | searx/tests/engines/test_btdigg.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/searx/tests/engines/test_btdigg.py b/searx/tests/engines/test_btdigg.py index 4947b71da..2721f4e7c 100644 --- a/searx/tests/engines/test_btdigg.py +++ b/searx/tests/engines/test_btdigg.py @@ -22,7 +22,7 @@ class TestBtdiggEngine(SearxTestCase): self.assertRaises(AttributeError, btdigg.response, '') self.assertRaises(AttributeError, btdigg.response, '[]') - response = mock.Mock(text='<html></html>') + response = mock.Mock(content='<html></html>') self.assertEqual(btdigg.response(response), []) html = """ @@ -82,7 +82,7 @@ class TestBtdiggEngine(SearxTestCase): </table> </div> """ - response = mock.Mock(text=html) + response = mock.Mock(content=html) results = btdigg.response(response) self.assertEqual(type(results), list) self.assertEqual(len(results), 1) @@ -101,7 +101,7 @@ class TestBtdiggEngine(SearxTestCase): </table> </div> """ - response = mock.Mock(text=html) + response = mock.Mock(content=html) results = btdigg.response(response) self.assertEqual(type(results), list) self.assertEqual(len(results), 0) @@ -367,7 +367,7 @@ class TestBtdiggEngine(SearxTestCase): </table> </div> """ - response = mock.Mock(text=html) + response = mock.Mock(content=html) results = btdigg.response(response) self.assertEqual(type(results), list) self.assertEqual(len(results), 5) |