summaryrefslogtreecommitdiff
path: root/tests/test_commands.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_commands.py')
-rw-r--r--tests/test_commands.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/test_commands.py b/tests/test_commands.py
index 73a0052..60d1e28 100644
--- a/tests/test_commands.py
+++ b/tests/test_commands.py
@@ -2205,6 +2205,15 @@ class TestRedisCommands(object):
# xread starting after the last message returns an empty message list
assert r.xreadgroup(group, consumer, streams={stream: '>'}) == expected
+ # xreadgroup with noack does not have any items in the PEL
+ r.xgroup_destroy(stream, group)
+ r.xgroup_create(stream, group, '0')
+ assert len(r.xreadgroup(group, consumer, streams={stream: '>'},
+ noack=True)[0][1]) == 2
+ # now there should be nothing pending
+ assert len(r.xreadgroup(group, consumer,
+ streams={stream: '0'})[0][1]) == 0
+
r.xgroup_destroy(stream, group)
r.xgroup_create(stream, group, '0')
# delete all the messages in the stream