diff --git a/src/tests/test_video_es_vec.py b/src/tests/test_video_es_vec.py index 4d91b0db..c1e645ea 100644 --- a/src/tests/test_video_es_vec.py +++ b/src/tests/test_video_es_vec.py @@ -98,4 +98,9 @@ def test_2_search_video_vector(self): search_result = es.find("video", average_vector.get('vid_vec')) print("SEARCH RESULTS \n : ") pp.pprint(search_result) - self.assertEqual(search_result[0]['dataset'], file_name) + file_found = False + for result in search_result: + if result.get('dataset') == file_name: + file_found = True + break + self.assertTrue(file_found, f"File {file_name} not found in any search result.")