diff options
author | Roey Prat <roey.prat@redislabs.com> | 2018-10-02 18:27:27 +0300 |
---|---|---|
committer | Roey Prat <roey.prat@redislabs.com> | 2018-10-28 12:12:53 +0200 |
commit | 7efb71bd81e365e94669ad1b1fff65c5f83b0508 (patch) | |
tree | 03d9c44a02e62ae5486d35485d52330cb2d3fee9 | |
parent | ce2231697d5dcd746f7b51b6a40b291b310e1f5f (diff) | |
download | redis-py-7efb71bd81e365e94669ad1b1fff65c5f83b0508.tar.gz |
Fixes to test_strict_xrange
-rw-r--r-- | tests/test_commands.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/test_commands.py b/tests/test_commands.py index b89b0c7..e6b727a 100644 --- a/tests/test_commands.py +++ b/tests/test_commands.py @@ -1615,7 +1615,7 @@ class TestStrictCommands(object): assert stamp1 != stamp2 milli, offset = stamp2.decode('utf-8').split('-') - new_id = ("%s-0" % (milli + 10000)).encode('utf-8') + new_id = "{}-0".format(int(milli) + 10000).encode('utf-8') stamp3 = sr.xadd(varname, id=new_id, foo="bar") assert sr.xlen(varname) == 3 assert stamp3 == new_id @@ -1637,7 +1637,7 @@ class TestStrictCommands(object): results = sr.xrange(varname, finish=stamp2, count=1) assert get_ids(results) == [stamp1] - results = sr.xrevrange(varname, start=stamp1) + results = sr.xrevrange(varname, start=stamp4) assert get_ids(results) == [stamp4, stamp3, stamp2, stamp1] results = sr.xrevrange(varname, start=stamp3, finish=stamp2) |