diff options
| author | Adam Tauber <asciimoo@gmail.com> | 2016-01-02 11:14:49 +0100 |
|---|---|---|
| committer | Adam Tauber <asciimoo@gmail.com> | 2016-01-10 19:23:10 +0100 |
| commit | 53979a7bf7669c803c2a493fbf136519f6a293e6 (patch) | |
| tree | 3b79da9408699108ba89b22cedf73cfff1fe59b7 /tests/unit/engines/test_dummy.py | |
| parent | f9186344b3642fb3d55d2dc46c96c6b25b8ccf41 (diff) | |
[mod] remove buildout/makefile infrastructure
Diffstat (limited to 'tests/unit/engines/test_dummy.py')
| -rw-r--r-- | tests/unit/engines/test_dummy.py | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/tests/unit/engines/test_dummy.py b/tests/unit/engines/test_dummy.py new file mode 100644 index 000000000..9399beaaf --- /dev/null +++ b/tests/unit/engines/test_dummy.py @@ -0,0 +1,26 @@ +from searx.engines import dummy +from searx.testing import SearxTestCase + + +class TestDummyEngine(SearxTestCase): + + def test_request(self): + test_params = [ + [1, 2, 3], + ['a'], + [], + 1 + ] + for params in test_params: + self.assertEqual(dummy.request(None, params), params) + + def test_response(self): + responses = [ + None, + [], + True, + dict(), + tuple() + ] + for response in responses: + self.assertEqual(dummy.response(response), []) |