MCPcopy
hub / github.com/github/spec-kit / test_execute_condition_false

Method test_execute_condition_false

tests/test_workflows.py:1827–1843  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1825 assert len(result.next_steps) == 1
1826
1827 def test_execute_condition_false(self):
1828 from specify_cli.workflows.steps.while_loop import WhileStep
1829 from specify_cli.workflows.base import StepContext
1830
1831 step = WhileStep()
1832 ctx = StepContext(
1833 steps={"run-tests": {"output": {"exit_code": 0}}}
1834 )
1835 config = {
1836 "id": "retry",
1837 "condition": "{{ steps.run-tests.output.exit_code != 0 }}",
1838 "max_iterations": 5,
1839 "steps": [{"id": "fix", "command": "speckit.implement"}],
1840 }
1841 result = step.execute(config, ctx)
1842 assert result.output["condition_result"] is False
1843 assert result.next_steps == []
1844
1845 def test_validate_missing_fields(self):
1846 from specify_cli.workflows.steps.while_loop import WhileStep

Callers

nothing calls this directly

Calls 3

executeMethod · 0.95
WhileStepClass · 0.90
StepContextClass · 0.90

Tested by

no test coverage detected