Browser specs: the page-per-assertion files share their set-up (new-run-wizard, run-tabs, settings) #229

Closed
opened 2026-10-20 19:23:16 -04:00 by cmoriarty · 1 comment
Owner

Tier 2 of the test-suite speed-up (#227). Summed test time in the browser step is 1,405 s; three files pay for a page load and a wizard walk per tiny assertion: new-run-wizard.spec.ts (34 tests, 159 s), run-tabs.spec.ts (23, 128 s), settings.spec.ts (24, 119 s). Twenty-three tests take 10 s or more (388 s together), led by Complete the project begins the first item… at 42.8 s.

Proposal: in each of those files, group the assertions that read one state of the page into one test or a describe with a shared beforeAll page where the state is not mutated; replace fixed waitForTimeout sleeps (49 across the suite) with waits on the condition; and look at the five tests over 20 s one by one. The spec tags (// spec: …) stay on each assertion group so the scenario coverage count does not change. Measure the file times before and after.

Tier 2 of the test-suite speed-up (#227). Summed test time in the browser step is 1,405 s; three files pay for a page load and a wizard walk per tiny assertion: new-run-wizard.spec.ts (34 tests, 159 s), run-tabs.spec.ts (23, 128 s), settings.spec.ts (24, 119 s). Twenty-three tests take 10 s or more (388 s together), led by `Complete the project begins the first item…` at 42.8 s. Proposal: in each of those files, group the assertions that read one state of the page into one test or a `describe` with a shared `beforeAll` page where the state is not mutated; replace fixed `waitForTimeout` sleeps (49 across the suite) with waits on the condition; and look at the five tests over 20 s one by one. The spec tags (`// spec: …`) stay on each assertion group so the scenario coverage count does not change. Measure the file times before and after.
Author
Owner

Closing on the measurement rather than a change. Once each worker had its own fixture (#228), the page-per-assertion files fell by themselves: new-run-wizard 159 s to 23 s, settings 119 s to 34 s, run-tabs 128 s to 47 s; summed test time 1,405 s to 542 s. Their slowness was the shared fixture, not their structure. The seven tests still over 10 s each measure a window (layout-stability, spine-activity, update-notice) and should. So no test is regrouped and no sleep is replaced.

Closing on the measurement rather than a change. Once each worker had its own fixture (#228), the page-per-assertion files fell by themselves: `new-run-wizard` 159 s to 23 s, `settings` 119 s to 34 s, `run-tabs` 128 s to 47 s; summed test time 1,405 s to 542 s. Their slowness was the shared fixture, not their structure. The seven tests still over 10 s each measure a window (`layout-stability`, `spine-activity`, `update-notice`) and should. So no test is regrouped and no sleep is replaced.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
cmoriarty/braid#229
No description provided.