Skip to content

Commit d0b54bc

Browse files
committed
Adjust tests
1 parent f2a5dbd commit d0b54bc

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

tests/integration/data/test_list_errors.py

+1
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ def seed_for_list2(idx, list_errors_namespace, wait=True):
2828

2929
@pytest.mark.usefixtures("seed_for_list2")
3030
class TestListErrors:
31+
@pytest.mark.skip(reason="Bug filed https://github.com/pinecone-io/pinecone-db/issues/9578")
3132
def test_list_change_prefix_while_fetching_next_page(self, idx, list_errors_namespace):
3233
results = idx.list_paginated(prefix="99", limit=5, namespace=list_errors_namespace)
3334
with pytest.raises(PineconeException) as e:

tests/integration/data/test_query.py

+10-2
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,11 @@ def test_query_by_vector_include_metadata(self, idx, query_namespace, use_nondef
115115
assert isinstance(results, QueryResponse) == True
116116
assert results.namespace == target_namespace
117117

118-
matches_with_metadata = [match for match in results.matches if match.metadata is not None]
118+
matches_with_metadata = [
119+
match
120+
for match in results.matches
121+
if match.metadata is not None and match.metadata != {}
122+
]
119123
assert len(matches_with_metadata) == 3
120124
assert find_by_id(results.matches, "4").metadata["genre"] == "action"
121125

@@ -134,7 +138,11 @@ def test_query_by_vector_include_values_and_metadata(
134138
assert isinstance(results, QueryResponse) == True
135139
assert results.namespace == target_namespace
136140

137-
matches_with_metadata = [match for match in results.matches if match.metadata is not None]
141+
matches_with_metadata = [
142+
match
143+
for match in results.matches
144+
if match.metadata is not None and match.metadata != {}
145+
]
138146
assert len(matches_with_metadata) == 3
139147
assert find_by_id(results.matches, "4").metadata["genre"] == "action"
140148
assert len(results.matches[0].values) == self.expected_dimension

0 commit comments

Comments
 (0)