File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed
tests/model_registry/model_catalog/huggingface Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -50,12 +50,20 @@ def test_source_status_duplicate_models(
5050 headers = model_registry_rest_headers ,
5151 )
5252 sources = response .get ("items" , [])
53+ expected_source_ids = {MIXED_SOURCE_ID , OVERLAPPING_SOURCE_ID }
54+ found_source_ids = set ()
5355 for source in sources :
54- if source ["id" ] in [MIXED_SOURCE_ID , OVERLAPPING_SOURCE_ID ]:
56+ if source ["id" ] in expected_source_ids :
57+ found_source_ids .add (source ["id" ])
5558 assert source ["status" ] == "available" , (
5659 f"Source '{ source ['id' ]} ' has status '{ source ['status' ]} ', expected 'available'. "
5760 f"Error: { source .get ('error' , 'N/A' )} "
5861 )
62+ missing_sources = expected_source_ids - found_source_ids
63+ assert not missing_sources , (
64+ f"Expected sources { missing_sources } not found in response. "
65+ f"Available source IDs: { [s ['id' ] for s in sources ]} "
66+ )
5967
6068 def test_shared_model_present_in_both_sources (
6169 self : Self ,
You can’t perform that action at this time.
0 commit comments