diff --git a/.github/workflows/controller-tests.yml b/.github/workflows/controller-tests.yml index 21739c62..37c5c7c4 100644 --- a/.github/workflows/controller-tests.yml +++ b/.github/workflows/controller-tests.yml @@ -1,10 +1,13 @@ name: Controller Tests +# `pull_request` is unfiltered for the same reason as jest-tests.yml: `branches: [master]` meant +# this never ran on a pull request into any other branch. It is why Controller Tests is absent +# from the checks on the pull request that moved this job to Python 3.13 -- the change to this +# file could not be verified by the run that contained it. on: push: branches: [master, feature/*] pull_request: - branches: [master] jobs: controller-tests: diff --git a/pytest.ini b/pytest.ini index aa680dee..2cfb2250 100644 --- a/pytest.ini +++ b/pytest.ini @@ -4,6 +4,19 @@ testpaths = wrolpi modules asyncio_default_fixture_loop_scope = function -# Do not remove timeout - tests should not run forever -timeout = 30 +# Do not remove timeout - tests should not run forever. +# +# This is a hang detector, not a performance budget. It was 30s, but the plugin was never +# declared in requirements.txt, so CI installed without it and the limit had never actually been +# applied there. The first run that enforced it failed sixteen tests, every one of them at +# 30.0s and none of them hung: CircleCI's 4 vCPU box runs this suite in roughly twice the +# wall-clock of a dev machine, and a cluster of refresh/worker tests sits at 28-30s there -- +# test_get_refresh_progress passed at 29.9s and test_create_playlist at 29.8s, which is luck +# rather than headroom. +# +# 120s is about four times the slowest legitimate test observed on CI, so it still catches a +# genuine hang long before CircleCI kills the job, while leaving slow-but-working tests alone. +# Raise it if CI grows slower; a named timeout failure is the point, and a limit tight enough to +# fire on healthy tests just trades one unreliable signal for another. +timeout = 120 timeout_method = signal