diff --git a/src/specify_cli/workflows/steps/gate/__init__.py b/src/specify_cli/workflows/steps/gate/__init__.py index e686a6a247..d32efdaaf4 100644 --- a/src/specify_cli/workflows/steps/gate/__init__.py +++ b/src/specify_cli/workflows/steps/gate/__init__.py @@ -26,7 +26,7 @@ class GateStep(StepBase): later with ``specify workflow resume``. The user's choice is stored in ``output.choice``. ``on_reject`` - controls abort / skip behaviour. + controls abort / skip / retry behaviour. """ type_key = "gate" diff --git a/tests/test_workflows.py b/tests/test_workflows.py index af5584d633..5347a36887 100644 --- a/tests/test_workflows.py +++ b/tests/test_workflows.py @@ -2100,6 +2100,15 @@ def test_validate_accepts_valid(self): class TestGateStep: """Test the gate step type.""" + def test_docstring_lists_every_on_reject_behaviour(self): + # The docstring must not contradict validate()/execute(): on_reject + # accepts 'abort', 'skip', AND 'retry' (execute() has a dedicated + # retry -> PAUSED branch), but the summary omitted 'retry'. + from specify_cli.workflows.steps.gate import GateStep + + for behaviour in ("abort", "skip", "retry"): + assert behaviour in GateStep.__doc__ + @pytest.fixture(autouse=True) def _non_tty_stdin_by_default(self, monkeypatch): # Default every gate test to a non-TTY stdin so none can drop into