@@ -76,7 +76,10 @@ def test_platform_source_refs_use_catalog(platform):
7676 validation_path = root / validation_script
7777 assert validation_path .is_file ()
7878 for task_name , task in config ["image_build" ]["tasks" ].items ():
79- assert re .fullmatch (r"[a-z0-9][a-z0-9._-]*[a-z0-9]" , task ["image" ])
79+ assert re .fullmatch (r"[a-z0-9][a-z0-9._/-]*[a-z0-9]" , task ["image" ])
80+ assert "//" not in task ["image" ]
81+ assert ":" not in task ["image" ]
82+ assert "@" not in task ["image" ]
8083 if task_name != "all" :
8184 assert (root / f"requirements/{ platform } /{ task_name } .txt" ).is_file ()
8285 assert (root / f"tools/install/{ platform } /install_{ task_name } .sh" ).is_file ()
@@ -89,16 +92,6 @@ def test_platform_source_refs_use_catalog(platform):
8992 assert re .search (rf"^ARG { build_arg } (?:=|$)" , dockerfile , re .MULTILINE )
9093
9194
92- def test_dev_image_name_matches_harbor_governance_contract ():
93- root = Path (__file__ ).parents [2 ]
94- workflow = (root / ".github/workflows/build_image_common.yml" ).read_text ()
95-
96- assert (
97- 'candidate="${registry}/flagos-dev/${image_name}:'
98- '${short_sha}-${PLATFORM}-dev"' in workflow
99- )
100-
101-
10295@pytest .mark .parametrize ("platform" , ["cuda" , "musa" , "ascend" , "metax" ])
10396def test_split_runtime_all_images_have_explicit_task_environments (platform ):
10497 root = Path (__file__ ).parents [2 ]
0 commit comments