summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorChayim <chayim@users.noreply.github.com>2021-09-30 10:54:07 +0300
committerGitHub <noreply@github.com>2021-09-30 10:54:07 +0300
commitcf3973237205d4bcd74d7cf22889ff10aac35539 (patch)
tree5dd9b8fd90c0a211225d85a75921c5cdbf072e5e /tests
parent491c938f9c6ea56fb0b3403be63168e6930709ae (diff)
downloadredis-py-cf3973237205d4bcd74d7cf22889ff10aac35539.tar.gz
Supporting args with MODULE LOAD (#1579)
Part of #1546
Diffstat (limited to 'tests')
-rw-r--r--tests/test_commands.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/test_commands.py b/tests/test_commands.py
index 254aba5..9f0a148 100644
--- a/tests/test_commands.py
+++ b/tests/test_commands.py
@@ -3461,6 +3461,16 @@ class TestRedisCommands:
assert isinstance(res, int)
assert res >= 100
+ @skip_if_server_version_lt('4.0.0')
+ def test_module(self, r):
+ with pytest.raises(redis.exceptions.ModuleError) as excinfo:
+ r.module_load('/some/fake/path')
+ assert "Error loading the extension." in str(excinfo.value)
+
+ with pytest.raises(redis.exceptions.ModuleError) as excinfo:
+ r.module_load('/some/fake/path', 'arg1', 'arg2', 'arg3', 'arg4')
+ assert "Error loading the extension." in str(excinfo.value)
+
class TestBinarySave: