docs(s41): verified Foundry auth recipe + necessary-but-not-sufficient note

This commit is contained in:
Kjell Tore Guttormsen 2026-07-15 11:24:18 +02:00
commit 123f71f547
2 changed files with 76 additions and 0 deletions

View file

@ -102,3 +102,14 @@ def test_malformed_override_is_structured_refusal(
rc = preflight.main(["--profile", "azure"])
assert rc == 1
assert capsys.readouterr().err.strip()
def test_auth_recipe_doc_exists_and_names_facts() -> None:
# SC8 doc-guard: the verified recipe lives in docs/ (NOT the preflight docstring, so the
# AST grep-guard stays clean) and pins the load-bearing facts so it can't rot silently. The
# English "necessary-but-not-sufficient" marker is distinct from the CLI's Norwegian marker.
doc = Path(__file__).resolve().parents[1] / "docs" / "2026-07-15-foundry-auth-recipe.md"
text = doc.read_text(encoding="utf-8")
assert "Foundry User" in text
assert "services.ai.azure.com" in text
assert "necessary-but-not-sufficient" in text