Files
box/fleet/tasks/done/132-rpa-test-speedup.md.muse--runtime--roles
T

14 lines
1.2 KiB
Plaintext

# 132-rpa-test-speedup: RPA test speedup
Goal: trim waits in third-slowest test file
Steps:
1. Read 118 result notes in done/118-slowest-tests.md.* for the #3 target (test_settings_rpa read_usage_stats_did_not_render, ~4s). 2. On a feature branch: reduce sleeps/timeouts keeping all assertions identical (never weaken tests); run the file until green. Done criteria: result notes list before/after seconds + pass count, or exact blocking failure.
Done criteria: result notes appended below; file moved to done/.
Result notes (append below before moving to done/):
Completed 2026-10-08T18:26:15Z via box tasks done:
DONE on branch builder/rpa-test-speedup (uncommitted, test-only, zero production change). ROOT CAUSE: did_not_render stubbed sleep but the read_usage poll loop spins on a real-time 4.0s deadline (busy-spin, 4.15s); blocked/not_redeemed each burned 2x0.4s real settle sleeps. FIX (tests/test_settings_rpa.py): fake clock (+1s per time.time read) for did_not_render so the loop still polls and still exits via timeout after ~4 reads; time.sleep no-op for blocked/not_redeemed. All assertions byte-identical. BEFORE/AFTER: file 6 passed 5.80s -> 0.06s (did_not_render 4.15s->~0s, blocked/not_redeemed 0.80s->~0s each). unittest: Ran 6 OK.