diff options
author | Binbin <binloveplay1314@qq.com> | 2022-01-15 15:13:53 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-15 09:13:53 +0200 |
commit | 440d28091b73a87f74450942dcdd81161ca50bbe (patch) | |
tree | bb7e7b2864306a60537dbea52ba81dc92fffbb78 /tests/cluster/tests | |
parent | 4db4b434175b519e2e5a78f2d33a7627c483c367 (diff) | |
download | redis-440d28091b73a87f74450942dcdd81161ca50bbe.tar.gz |
Fix function no-cluster flag test (#10115)
Fixes cluster test introduced in #10066.
```
Function no-cluster flag: ERR Error registering functions: @user_function: 1: wrong number of arguments to redis.register_function
```
Diffstat (limited to 'tests/cluster/tests')
-rw-r--r-- | tests/cluster/tests/00-base.tcl | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/cluster/tests/00-base.tcl b/tests/cluster/tests/00-base.tcl index 6ff043497..ff5044496 100644 --- a/tests/cluster/tests/00-base.tcl +++ b/tests/cluster/tests/00-base.tcl @@ -64,7 +64,9 @@ test "It is possible to write and read from the cluster" { } test "Function no-cluster flag" { - R 1 function load lua test {redis.register_function('f1', function() return 'hello' end, {'no-cluster'})} + R 1 function load lua test { + redis.register_function{function_name='f1', callback=function() return 'hello' end, flags={'no-cluster'}} + } catch {R 1 fcall f1 0} e assert_match {*Can not run function on cluster, 'no-cluster' flag is set*} $e } |