Skip to content

Commit a53c35b

Browse files
committed
Fix bug: new stream id used for test_streams
1 parent f61ec92 commit a53c35b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

tests/client/test_streams.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ async def test_xreadgroup(self, r):
103103
with pytest.raises(ResponseError) as exc:
104104
await r.xreadgroup('wrong_group', 'lalala', count=10, block=10, test_stream='1')
105105
assert await r.xgroup_create('test_stream', 'test_group', '0') is True
106-
entries = await r.xreadgroup('test_group', 'consumer1', count=5, test_stream='1')
106+
entries = await r.xreadgroup('test_group', 'consumer1', count=5, test_stream='>')
107107
assert len(entries[b'test_stream']) == 5
108108

109109
@skip_if_server_version_lt('4.9.103')
@@ -132,7 +132,7 @@ async def test_xgroup_set_id(self, r):
132132
group_info = await r.xinfo_groups('test_stream')
133133
assert group_info[0][b'pending'] == 0
134134
assert await r.xgroup_set_id('test_stream', 'test_group', '0') is True
135-
await r.xreadgroup('test_group', 'consumer1', count=5, test_stream='1')
135+
await r.xreadgroup('test_group', 'consumer1', count=5, test_stream='>')
136136
group_info = await r.xinfo_groups('test_stream')
137137
assert group_info[0][b'pending'] == 5
138138

@@ -179,11 +179,11 @@ async def test_xpending(self, r):
179179
assert group_info[0][b'pending'] == 0
180180
assert len(await r.xpending('test_stream', 'test_group', count=10, consumer='consumer1')) == 0
181181
assert await r.xgroup_set_id('test_stream', 'test_group', '0') is True
182-
await r.xreadgroup('test_group', 'consumer1', count=5, test_stream='1')
182+
await r.xreadgroup('test_group', 'consumer1', count=5, test_stream='>')
183183
group_info = await r.xinfo_groups('test_stream')
184184
assert group_info[0][b'pending'] == 5
185185
assert len(await r.xpending('test_stream', 'test_group', count=10, consumer='consumer1')) == 5
186-
xpending_entries_in_range = await r.xpending('test_stream', 'test_group', start='1', end='2', count=10,
186+
xpending_entries_in_range = await r.xpending('test_stream', 'test_group', start='2', end='2', count=10,
187187
consumer='consumer1')
188188
assert len(xpending_entries_in_range) == 1
189189
assert xpending_entries_in_range[0][0] == b'2-0'

0 commit comments

Comments
 (0)