Repository navigation
test(ui): share native attachment transfer fixture - #181002
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex review: needs maintainer review before merge. What this changesThis PR extracts a shared fixture for native file-to-session attachment lifetime tests. Example: Attach notes.md, then replace the panel content before its download finishes.
Review scores
ProductKind: Test only · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Keep this PR open: it removes duplicated test setup while preserving all three lifetime cases, with no actionable findings. Priority: P3 Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherThe Control UI detail panel passes downloaded file bytes to the composer attachment owner; these tests cover cancellation on replacement and survival across same-turn reparenting. flowchart LR
A[Shared test fixture] --> B[Native detail panel]
B --> C[Attach menu action]
C --> D[Attachment transfer owner]
D --> E[Held download]
D --> F[Composer attachments]
Technical reviewBest possible solution: Retain the local shared fixture and all three distinct lifetime cases without changing production code. Do we have a high-confidence way to reproduce the issue? No product defect is claimed; source comparison confirms duplicated setup, and the PR reports the retained three-case suite passing. Is this the best way to solve the issue? The extraction is appropriately local, preserves the await boundary after starting the transfer, and keeps each distinct behavior assertion in its original case. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against bfd83de78851. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceTests -37. Total -37 across 1 file. Added test files: 0. View PR surface stats
LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed October 22, 2026, 5:39 PM ET / 21:39 UTC. |
|
Merged via squash auto-merge.
|
What Problem This Solves
The native file-to-session attachment lifetime tests repeat the same held-download, composer, panel, and menu setup.
User Impact
No production or user-visible change. The same three cases still exercise synchronous cancellation on content or destination replacement and successful attachment after same-turn reparenting.
Why This Change Was Made
A local fixture starts the real native menu action and returns the held download and observed pending-read state. Every behavior assertion remains in its original case, including checking abort and pending-read release before awaiting the replacement render. No production injection hook or test-only export was added.
Test LOC: 153 → 116 (−37). Production LOC delta: 0.
Evidence
pnpm tsgo:uigit diff --checkci:fullrequestedNo screenshots: production rendering is unchanged. Both retirement cases and the reparenting-success case remain separate tests; only setup is shared.