no-mistakes(review): Fix compression example alias; make retired aliases fail audit
This commit is contained in:
@@ -87,3 +87,21 @@ def test_retired_gemma_is_rejected(tmp_path):
|
||||
assert code == 1, out
|
||||
assert "auxiliary.vision.model must be gpu-vision" in out
|
||||
assert "RESULT: FAIL" in out
|
||||
|
||||
|
||||
def test_retired_alias_in_delegation_is_rejected(tmp_path):
|
||||
"""delegation.model has no dedicated value rule, so a retired name there used to PASS."""
|
||||
cfg = tmp_path / "delegation-gpu-light.yaml"
|
||||
cfg.write_text(
|
||||
BASE.format(alias="gpu-vision").replace(
|
||||
"delegation:\n provider: harness",
|
||||
"delegation:\n provider: harness\n model: gpu-light",
|
||||
)
|
||||
)
|
||||
proc = subprocess.run(
|
||||
[sys.executable, str(AUDIT), str(cfg)],
|
||||
capture_output=True, text=True,
|
||||
)
|
||||
assert proc.returncode == 1, proc.stdout
|
||||
assert "delegation.model = 'gpu-light' is retired" in proc.stdout
|
||||
assert "RESULT: FAIL" in proc.stdout
|
||||
|
||||
Reference in New Issue
Block a user