docs: define strict dry-run contract
# Conflicts: # .secrets.baseline
This commit is contained in:
@@ -11,6 +11,23 @@ from pronote_sync.errors import PipelineCriticalError, PipelineWarning
|
||||
from pronote_sync.models.pronote import PronoteData
|
||||
|
||||
|
||||
def test_help_documents_strict_dry_run_contract(capsys: pytest.CaptureFixture[str]) -> None:
|
||||
"""L'aide CLI expose le contrat strict et l'incompatibilité QR/token.
|
||||
|
||||
:param capsys: Capture des sorties standard de pytest.
|
||||
:return: None
|
||||
"""
|
||||
from pronote_sync.cli.main import main
|
||||
|
||||
with pytest.raises(SystemExit) as exc_info:
|
||||
main(["--help"])
|
||||
|
||||
output = " ".join(capsys.readouterr().out.split())
|
||||
assert exc_info.value.code == 0
|
||||
assert "sans sortie distante ni état local persistant" in output
|
||||
assert "PRONOTE_AUTH_MODE=qr_token" in output
|
||||
|
||||
|
||||
def test_main_runs_composition_root_in_dry_run_with_requested_log_level(
|
||||
mocker: MockerFixture,
|
||||
) -> None:
|
||||
|
||||
Reference in New Issue
Block a user