X-Git-Url: https://git.saurik.com/redis.git/blobdiff_plain/a7159fe817b163d17ff64fae0d459bbe786280ef..21dbc6499a538af07f52a41742cf1683f3fc9c23:/tests/unit/cas.tcl diff --git a/tests/unit/cas.tcl b/tests/unit/cas.tcl index dc6a5ef7..d420d9e2 100644 --- a/tests/unit/cas.tcl +++ b/tests/unit/cas.tcl @@ -111,4 +111,25 @@ start_server {tags {"cas"}} { r ping r exec } {PONG} + + test {WATCH will consider touched keys target of EXPIRE} { + r del x + r set x foo + r watch x + r expire x 10 + r multi + r ping + r exec + } {} + + test {WATCH will not consider touched expired keys} { + r del x + r set x foo + r expire x 2 + r watch x + after 3000 + r multi + r ping + r exec + } {PONG} }