Repository navigation
test(psa): give the bulk-submit cases of hotcrm#2764 a measured budget (#2849) - #2854
Merged
objectstack-fleet[bot] merged 1 commit intoNov 29, 2026
Merged
Conversation
The four bulk-click cases of test/psa-approvals.test.ts (and the locked Draft report case beside them) each take two projects through initiation approval, a travel request through its approval, and then one click that writes and submits three reports. Locally they run 1.6-3.1 s; on CI shard 2 the trip cases ran 3.7-5.0 s on main and failed at 5174, 5211 and 5426 ms on two unrelated PRs. Nothing waits on a loop (the approval-request wait returns on its first poll) and the project task hook of #2771 changed nothing (measured on ee9fccd), so the cases get their own 15 s budget with the reading beside it, as test/import-values-accepted.test.ts does. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017xRBcV3h25dAMNWki8e1ns
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
Author
|
repo:hotcrm#2 · sunhaolin · session_017xRBcV3h25dAMNWki8e1ns 维护者速读
席位核对 — ACCEPT · repo:hotcrm#2 · head 04ae01b
|
sunhaolin
pushed a commit
that referenced
this pull request
Nov 29, 2026
Brings in the shard-2 timeout fix from #2854. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017xRBcV3h25dAMNWki8e1ns
sunhaolin
pushed a commit
that referenced
this pull request
Nov 29, 2026
Brings in the shard-2 timeout fix from #2854. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017xRBcV3h25dAMNWki8e1ns
huangyiirene
pushed a commit
that referenced
this pull request
Nov 29, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01J8VVAk8tegvAi1ECkgCFfc
This was referenced Nov 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #2849
Metadata-impact: none (test-only: no file under
src/changes)Clause-②: no
Metadata-protocol: none
维护者速读
What changes
test/psa-approvals.test.ts, describe "an expense report is not submitted on a locked, closed or cancelled project (hotcrm#2764)":submit_for_reimbursement/submit_trip_for_reimbursementover a locked, closed or cancelled project) get their own 15 s budget, with the measured reading and the cause beside it, in the pattern oftest/import-values-accepted.test.ts:90;No assertion is changed, nothing is skipped, and the global
testTimeoutis untouched. The changeset is empty-frontmatter (test-only, nothing ships).Tests
The cause, measured. The cases are heavy by construction, and were born close to the 5 s default:
vi.waitForon the approval requests resolves on its first poll (1 ms) — no wait loop;#2771's project task hook changed nothing: trip cases 2.14-2.40 s onee9fccd9f(before it) vs 2.14-2.28 s on142e7a17, same box, interleaved;#2845made these flows faster on CI (puts the expenses of each project: 2.9-3.1 s ond72de417→ 1.6-1.8 s on332710e8);#2820) made the shared work 15-25 % slower locally (332710e818.6.0 vsc6e64eed19.0.0-next.2: file tests 24.0-25.3 s → 28.7-29.0 s;is approved by a Project Director517-535 → 644-711 ms) — platform side, already carried by automation: on 19.0.0-next.2, the run-history overflow prune warns "Record run_… not found in sys_automation_run" for rows it just counted (57 per test shard in hotcrm) objectstack#38303;ee9fccd9f(the commit that added them), 3.69-4.15 s on526f21c5, 4.05-4.97 s on142e7a17, and failed at 5174/5211 ms (019931ca, job 141168379949) and 5426 ms (72326bed, job 141183406038). CI/local ratio ≈ 2.2-2.5×.Local readings (`--maxWorkers=2`, shared box)
142e7a17full file ×3142e7a17-t trip×2ee9fccd9ffull file ×204ae01b0full file ×3Acceptance notes
keeps the flow's turn-back as the backstop …case already carries a 60 s budget (6.2-7.0 s on CI shard 2); untouched.Verification
Two-minute check:
pnpm exec vitest run --maxWorkers=2 test/psa-approvals.test.ts— expectTests 29 passed (29), the trip cases around 2.2 s locally.Read first:
test/psa-approvals.test.ts— the two}, 15_000);lines and the comment block above the bulk-clickit.each.Gates on
04ae01b0:pnpm validateexit 0 (✓ Validation passed),pnpm typecheckexit 0,pnpm lintexit 0 (54 suggestions, no errors),pnpm hygieneexit 0 (✓ source hygiene clean), psa file ×3 exit 0 (29/29 each, 49.5-50.1 s).🤖 Generated with Claude Code
https://claude.ai/code/session_017xRBcV3h25dAMNWki8e1ns