Skip to content

tests: remove accidental waits, duplicate runs and checks of wording - #128

Merged
krokicki merged 5 commits into
mainfrom
faster-tests
Dec 1, 2026
Merged

krokicki merged 5 commits into
mainfrom
faster-tests

Conversation

@krokicki

@krokicki krokicki commented Dec 1, 2026 •

Copy link
Copy Markdown
Member

Why

CI takes six minutes, and 5 min 43 s of that is pytest. Part of that time was waiting on nothing, and an audit of the suite found tests that repeat a scenario, tests that check wording, and one assertion that could not fail.

What changes

Waits removed (about two minutes)

  • One test slept a real minute: the _jobs helper in tests/test_autodev_jobs.py built the job runner with its production poll interval of 60 s. It now passes poll_s=0.
  • Every test server took up to 0.5 s to stop, about 68 s of teardown across the suite. The eight test servers now start with serve_forever(poll_interval=0.01).
  • The 21 recorded-history tests each started a Temporal test server and used it only when recording. They now start one only when their recording switch is set; every recorded history is kept and replayed as before.

Tests removed or merged

  • Four page tests that searched the source for wording: four strings in the combined source, banned words in the docs and in comments, and the host dialog's texts. The dialog's interaction test already reads those from the dialog as it runs. The docs' route, chapter links and figure labels stay checked.
  • The stage matrices of a dataset's resume and a buffer's edit through the route go from 20 cases to four: one taken and one refused each. Which stages take them is the stage tables', and the table tests check the exact sets. The revoked, shelved and stale-revision cases stay.
  • Two pairs of workflow tests ran the same round for one assertion each. Each pair is now one run with both assertions.
  • The replay test that only changed a log format is gone. The recorded-history test beside it stays.

Assertions made real

  • The set id of a send-back and of a revoke was looked for in the workflow's source, within a window around two phrases. It is now asserted in the entry the workflow writes, and the source scan is gone.
  • The catalog snapshot test asserted a Path, which is always true. It now checks that the newer commit's file exists.

No code outside tests/ is touched.

Measured

On main, pytest runs 1,969 tests in 5 min 43 s. With this PR it runs 1,946 tests in 2 min 53 s, and the whole CI job takes 3 min 9 s, down from 6 min 6 s.

🤖 Generated with Claude Code

krokicki and others added 5 commits December 1, 2026 11:29
… once

The job runner helper polled at the production 60 s, so one test slept a
minute; the test servers' shutdown waited out serve_forever's 0.5 s poll in
every teardown. Together about two of the suite's five and a half minutes.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Searches of the page's source for strings, banned words in the docs and in
comments, and the host dialog's texts, which the dialog's interaction test
reads from the dialog as it runs. The docs' route, chapter links and figure
labels stay checked.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Which stages take a resume or an edit is the stage tables', and the table
tests check the exact sets; the route keeps one taken and one refused case
of each (16 cases fewer).

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…exists

The assertion was a Path, which is always true.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Two pairs of tests ran the same round for one assertion each: the
assertions are kept in one run. The set id of a send-back and of a revoke
is asserted in the entry the workflow writes, not found in its source. The
replay that changed a log format is gone; the recorded history beside it
stays. The 21 recorded-history tests start a Temporal test server only when
they record.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@krokicki krokicki changed the title tests: remove two accidental waits (about two minutes of the suite) tests: remove accidental waits, duplicate runs and checks of wording Dec 1, 2026
@krokicki
krokicki merged commit ddefa7c into main Dec 1, 2026
1 check passed
@krokicki
krokicki deleted the faster-tests branch December 1, 2026 17:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant