mirror of
https://github.com/harvard-edge/cs249r_book.git
synced 2026-07-16 23:24:55 -05:00
18 lines
399 B
Python
18 lines
399 B
Python
from pathlib import Path
|
|
|
|
from book.cli.checks.cli_contract import CASES, run_contract
|
|
|
|
|
|
ROOT = Path(__file__).resolve().parents[2]
|
|
|
|
|
|
def test_binder_cli_contract_is_stable():
|
|
violations = run_contract(ROOT)
|
|
|
|
rendered = "\n".join(
|
|
f"{v.code}: {v.message}\n{v.context}\n{v.suggestion}"
|
|
for v in violations
|
|
)
|
|
assert not violations, rendered
|
|
assert len(CASES) >= 10
|