Skip to content

Fix Linting and Test Failures #2191

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
May 23, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion redis/commands/search/commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ def dropindex(self, delete_documents=False):
### Parameters:

- **delete_documents**: If `True`, all documents will be deleted.

For more information see `FT.DROPINDEX <https://redis.io/commands/ft.dropindex>`_.
""" # noqa
keep_str = "" if delete_documents else "KEEPDOCS"
Expand Down
5 changes: 3 additions & 2 deletions tests/test_asyncio/test_json.py
Original file line number Diff line number Diff line change
Expand Up @@ -899,11 +899,12 @@ async def test_clear_dollar(modclient: redis.Redis):
"nested3": {"a": {"baz": 50}},
},
)

# Test multi
assert await modclient.json().clear("doc1", "$..a") == 4
assert await modclient.json().clear("doc1", "$..a") == 3

assert await modclient.json().get("doc1", "$") == [
{"nested1": {"a": {}}, "a": [], "nested2": {"a": ""}, "nested3": {"a": {}}}
{"nested1": {"a": {}}, "a": [], "nested2": {"a": "claro"}, "nested3": {"a": {}}}
]

# Test single
Expand Down
5 changes: 2 additions & 3 deletions tests/test_json.py
Original file line number Diff line number Diff line change
Expand Up @@ -893,7 +893,6 @@ def test_type_dollar(client):

@pytest.mark.redismod
def test_clear_dollar(client):

client.json().set(
"doc1",
"$",
Expand All @@ -905,10 +904,10 @@ def test_clear_dollar(client):
},
)
# Test multi
assert client.json().clear("doc1", "$..a") == 4
assert client.json().clear("doc1", "$..a") == 3

assert client.json().get("doc1", "$") == [
{"nested1": {"a": {}}, "a": [], "nested2": {"a": ""}, "nested3": {"a": {}}}
{"nested1": {"a": {}}, "a": [], "nested2": {"a": "claro"}, "nested3": {"a": {}}}
]

# Test single
Expand Down