diff options
author | antirez <antirez@gmail.com> | 2019-01-28 11:44:10 +0100 |
---|---|---|
committer | antirez <antirez@gmail.com> | 2019-01-28 11:44:10 +0100 |
commit | 3c67c1c3940e13351eab2310681bef09b3c3642d (patch) | |
tree | b9fc158cce2a72e5fdaa9b28aabc9ffa468570ff | |
parent | 9fc1ce2f05d377d7c8d461b2b7cd7dfff3618b3d (diff) | |
download | redis-3c67c1c3940e13351eab2310681bef09b3c3642d.tar.gz |
ACL: Test: enabled/disabled user.
-rw-r--r-- | tests/unit/acl.tcl | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/unit/acl.tcl b/tests/unit/acl.tcl index fcd5a0cad..e294c6c80 100644 --- a/tests/unit/acl.tcl +++ b/tests/unit/acl.tcl @@ -2,4 +2,19 @@ start_server {tags {"acl"}} { test {Connections start with the default user} { r ACL WHOAMI } {default} + + test {It is possible to create new users} { + r ACL setuser newuser + } + + test {New users start disabled} { + r ACL setuser newuser >passwd1 + catch {r AUTH newuser passwd1} err + set err + } {*WRONGPASS*} + + test {Enabling the user allows the login} { + r ACL setuser newuser on + r AUTH newuser passwd1 + } {OK} } |