Skip to content

Commit

Permalink
Fix async tests
Browse files Browse the repository at this point in the history
  • Loading branch information
gerzse committed Jul 4, 2024
1 parent fcd9670 commit 35efa8e
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/integration.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ jobs:
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
- name: run tests
- name: Run tests
run: |
pip install -U setuptools wheel
pip install -r requirements.txt
Expand Down
2 changes: 1 addition & 1 deletion tests/test_asyncio/test_cwe_404.py
Original file line number Diff line number Diff line change
Expand Up @@ -261,4 +261,4 @@ async def doit():

await asyncio.gather(*[doit() for _ in range(10)])
finally:
await r.close()
await r.aclose()
4 changes: 2 additions & 2 deletions tests/test_asyncio/test_search.py
Original file line number Diff line number Diff line change
Expand Up @@ -1511,14 +1511,14 @@ async def test_withsuffixtrie(decoded_r: redis.Redis):

# create withsuffixtrie index (text fields)
assert await decoded_r.ft().create_index(TextField("t", withsuffixtrie=True))
waitForIndex(decoded_r, getattr(decoded_r.ft(), "index_name", "idx"))
await waitForIndex(decoded_r, getattr(decoded_r.ft(), "index_name", "idx"))
info = await decoded_r.ft().info()
assert "WITHSUFFIXTRIE" in info["attributes"][0]["flags"]
assert await decoded_r.ft().dropindex("idx")

# create withsuffixtrie index (tag field)
assert await decoded_r.ft().create_index(TagField("t", withsuffixtrie=True))
waitForIndex(decoded_r, getattr(decoded_r.ft(), "index_name", "idx"))
await waitForIndex(decoded_r, getattr(decoded_r.ft(), "index_name", "idx"))
info = await decoded_r.ft().info()
assert "WITHSUFFIXTRIE" in info["attributes"][0]["flags"]

Expand Down

0 comments on commit 35efa8e

Please sign in to comment.