Skip to content

Commit b59492b

Browse files
authored
added a test to quety.timeout(0)
1 parent b7e52cb commit b59492b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tests/test_search.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2264,6 +2264,8 @@ def test_withsuffixtrie(client: redis.Redis):
22642264
def test_query_timeout(r: redis.Redis):
22652265
q1 = Query("foo").timeout(5000)
22662266
assert q1.get_args() == ["foo", "TIMEOUT", 5000, "LIMIT", 0, 10]
2267+
q1 = Query("foo").timeout(0)
2268+
assert q1.get_args() == ["foo", "TIMEOUT", 0, "LIMIT", 0, 10]
22672269
q2 = Query("foo").timeout("not_a_number")
22682270
with pytest.raises(redis.ResponseError):
22692271
r.ft().search(q2)

0 commit comments

Comments
 (0)