test_frv_perf.py python
28 lines 929 B
Raw
sha256:8461d44b77376fbf06fa7c3e085d309e3010fd8d5886d63c63e69ce118811ad4 docs: record AFF-b feature-tip SHAs after AFF-b-ISR commit. Human 4 days ago
1 """Performance tests for FRV (§FRV.12)."""
2
3 from __future__ import annotations
4
5 import time
6 from pathlib import Path
7
8 from adapters.config import load_config
9 from tests.support import write_config
10 from tools.freeze_authorization.resolve import freeze_authorization_state
11
12
13 def test_authorization_state_bounded(tmp_path: Path) -> None:
14 write_config(tmp_path, "config-git-only.yaml")
15 docs = tmp_path / "docs"
16 docs.mkdir()
17 art = docs / "PHASE-FRV.md"
18 art.write_text(
19 "```yaml\nphase: FRV\noutputs:\n - id: a\n path: docs/a.md\n frozen: true\n"
20 "review_stamp:\n verdict: pass\n```\n",
21 encoding="utf-8",
22 )
23 config = load_config(tmp_path / ".overseer" / "config.yaml")
24 start = time.perf_counter()
25 for _ in range(20):
26 freeze_authorization_state(tmp_path, art, phase_id="FRV-b", config=config)
27 elapsed = time.perf_counter() - start
28 assert elapsed < 5.0
File History 1 commit
sha256:8461d44b77376fbf06fa7c3e085d309e3010fd8d5886d63c63e69ce118811ad4 docs: record AFF-b feature-tip SHAs after AFF-b-ISR commit. Human 4 days ago