From 0947ce09c9dfc102a2b4e1057ea524bdd8a66b4a Mon Sep 17 00:00:00 2001 From: Hubert Ciebiada Date: Sun, 19 Apr 2026 01:46:45 +0200 Subject: [PATCH] Issue #166: Remove continue-on-error from simulation CI job Make the Simulation tests CI job a hard gate for merges to master so scenario regressions block the release instead of being silently ignored. Also document the three pytest markers (unit, simulation, slow) and how to skip the slow tier locally in README's Running Tests section, including an explicit note that the Simulation tests job now blocks merge. --- .github/workflows/ci.yml | 1 - README.md | 11 +++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7bd392d..6822863 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -75,7 +75,6 @@ jobs: simulation-tests: name: Simulation tests runs-on: ubuntu-latest - continue-on-error: true steps: - uses: actions/checkout@v4 diff --git a/README.md b/README.md index c0d1d44..cbdba3e 100644 --- a/README.md +++ b/README.md @@ -231,6 +231,12 @@ pip install -e ".[dev]" ### Running Tests +The test suite uses three pytest markers: + +- `@pytest.mark.unit` -- fast, isolated tests (run by default in the `Unit tests` CI job). +- `@pytest.mark.simulation` -- scenario-based tests that exercise the building simulator end-to-end. These run in the `Simulation tests` CI job and **block merge on failure**. +- `@pytest.mark.slow` -- longer-running scenarios (capped at a 3-day horizon). These still run in CI as part of the simulation job; locally you can skip them with `-m "not slow"` for a faster feedback loop. + ```bash # All tests pytest @@ -241,10 +247,15 @@ pytest tests/unit/ # Simulation scenarios (slower, includes full-year runs) pytest tests/simulation/ +# Simulation scenarios (fast subset, skip 3-day slow tier) +pytest tests/simulation/ -m "simulation and not slow" + # With coverage pytest --cov=pumpahead --cov-report=html ``` +The CI `Simulation tests` job is a hard gate -- any simulation regression blocks merge to `master`. + ### Code Quality ```bash