summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorSalvatore Sanfilippo <antirez@gmail.com>2016-01-15 16:24:06 +0100
committerSalvatore Sanfilippo <antirez@gmail.com>2016-01-15 16:24:06 +0100
commit8637384191ade8afbe380c10c2596f4dbc1eedbc (patch)
treedd82fec6f77c98ca598ed0b9c7c978fb0884380b /tests
parent5432fc81dbe828aeb9af05549250ffc9557838a0 (diff)
parent97a2248309937a2cecb8b800af40526e06fc64c4 (diff)
downloadredis-8637384191ade8afbe380c10c2596f4dbc1eedbc.tar.gz
Merge pull request #2726 from seppo0010/patch-2
Fix race condition in unit/introspection
Diffstat (limited to 'tests')
-rw-r--r--tests/unit/introspection.tcl7
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/unit/introspection.tcl b/tests/unit/introspection.tcl
index 342bb939a..f6477d9c5 100644
--- a/tests/unit/introspection.tcl
+++ b/tests/unit/introspection.tcl
@@ -6,16 +6,17 @@ start_server {tags {"introspection"}} {
test {MONITOR can log executed commands} {
set rd [redis_deferring_client]
$rd monitor
+ assert_match {*OK*} [$rd read]
r set foo bar
r get foo
- list [$rd read] [$rd read] [$rd read]
- } {*OK*"set" "foo"*"get" "foo"*}
+ list [$rd read] [$rd read]
+ } {*"set" "foo"*"get" "foo"*}
test {MONITOR can log commands issued by the scripting engine} {
set rd [redis_deferring_client]
$rd monitor
- r eval {redis.call('set',KEYS[1],ARGV[1])} 1 foo bar
$rd read ;# Discard the OK
+ r eval {redis.call('set',KEYS[1],ARGV[1])} 1 foo bar
assert_match {*eval*} [$rd read]
assert_match {*lua*"set"*"foo"*"bar"*} [$rd read]
}