@@ -193,7 +193,7 @@ def test_agent_header(self, store: ElasticsearchStore) -> None:
193
193
def test_similarity_search (
194
194
self , store : ElasticsearchStore , static_hits : List [Dict ]
195
195
) -> None :
196
- store ._store .search = Mock (return_value = static_hits )
196
+ store ._store .search = Mock (return_value = static_hits ) # type: ignore[assignment]
197
197
actual1 = store .similarity_search (
198
198
query = "test" ,
199
199
k = 7 ,
@@ -210,7 +210,7 @@ def test_similarity_search(
210
210
custom_query = self .dummy_custom_query ,
211
211
)
212
212
213
- store ._store .search = Mock (return_value = static_hits )
213
+ store ._store .search = Mock (return_value = static_hits ) # type: ignore[assignment]
214
214
215
215
actual2 = store .similarity_search_with_score (
216
216
query = "test" ,
@@ -230,7 +230,7 @@ def test_similarity_search(
230
230
def test_similarity_search_by_vector_with_relevance_scores (
231
231
self , store : ElasticsearchStore , static_hits : List [Dict ]
232
232
) -> None :
233
- store ._store .search = Mock (return_value = static_hits )
233
+ store ._store .search = Mock (return_value = static_hits ) # type: ignore[assignment]
234
234
actual = store .similarity_search_by_vector_with_relevance_scores (
235
235
embedding = [1 , 2 , 3 ],
236
236
k = 7 ,
@@ -335,7 +335,7 @@ def test_max_marginal_relevance_search(
335
335
) -> None :
336
336
hybrid_store ._store .max_marginal_relevance_search = Mock (
337
337
return_value = static_hits
338
- )
338
+ ) # type: ignore[assignment]
339
339
actual = hybrid_store .max_marginal_relevance_search (
340
340
query = "qqq" ,
341
341
k = 8 ,
0 commit comments