Repository navigation
test(app): fix pre-existing red in composer-editable-on-snapshot-error (missing PlatformProvider / run-mode menu) - #4802
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
3 Skipped Deployments
|
Warden review summary — ClearNative findings: 0. Blocking policy matches before consolidation: 0. Full finding text remains in Warden's native checks and review threads. This comment retains only native IDs, severity, skill attribution, and safe locations. Analysis run Reported trigger coverage (not proof of complete repository or context coverage): diff-security-review (8539 ms), confidentiality-review (8488 ms), desktop-den-sync-review (9784 ms). Blockers
Advisories
Needs recheck
Observed review-thread metrics
Thread states are read-only collection snapshots. These metrics are neither lifetime totals nor exact resolution times, and this summary is not clearance authority. |
There was a problem hiding this comment.
Warden security clearance: clear. No blocking findings (security or desktop↔den sync) in this diff (f2629144ff295bcd6af4258b34540740785e38a1). Automated clearance satisfies the required-review gate only — a human still reviews and merges. Analysis run
|
Passed · 10/10 tests · 15/15 assertions · 5 images Commit |
…he snapshot-error composer test apps/app/tests/composer-editable-on-snapshot-error.test.tsx has been red on dev since #4293 (composer renders WorkspaceRunModeMenu, which reads DesktopConfigProvider) and #4650 (message list renders ActionContextMenu, which reads PlatformProvider). Both providers exist at the real app root, so this is test drift, not a product regression. Mirror the fix already applied to composer-focus-continuity.test.tsx in #4631 and #4640.
f262914 to
89a90bf
Compare
There was a problem hiding this comment.
Warden security clearance: clear. No blocking findings (security or desktop↔den sync) in this diff (89a90bf815ca9d1ecbcdb56803a370ebea0ddcba). Automated clearance satisfies the required-review gate only — a human still reviews and merges. Analysis run
Summary
apps/app/tests/composer-editable-on-snapshot-error.test.tsxfails on cleanorigin/devwithPlatform context is missing. This is a test-only fix: the session surface grew two provider requirements after the test was written, and the real app root already supplies both, so there is no product regression. Found as a pre-existing red during #4797 and left unowned.Diagnosis (diagnose-a-red-run)
Red on clean
origin/dev@e925c7c99(control worktree,apps/app):Bisect (
git bisect start e925c7c99 947ed0cf4, good = the commit that added the test, 8 steps) shows two stacked breaks:94649b44afeat: choose workspace run modes from the composer (feat: choose workspace run modes from the composer #4293) — first bad commit.SessionSurfacenow renders<WorkspaceRunModeMenu>, which callsuseDesktopRestriction→useDesktopConfig()→ throwsuseDesktopConfig must be used within a DesktopConfigProvider.be5ab613cfeat(desktop): use native right-click menus (feat(desktop): use native right-click menus #4650) — message list now renders<ActionContextMenu>→usePlatform()→ throwsPlatform context is missing(the error visible on HEAD, masking Idea: Rename into Labori #1).Product check:
PlatformProvideris mounted insrc/index.react.tsx:51andDesktopConfigProviderinsrc/react-app/shell/providers.tsx:61,71, so the shipped tree is fine. The sibling testcomposer-focus-continuity.test.tsxwas already patched for exactly these two breaks in #4631 (mockWorkspaceRunModeMenu) and #4640 (PlatformProviderwrapper); this test was missed.Fix
Mirror the sibling test: wrap the surface in
PlatformProviderwithcreateDefaultPlatform()and mockWorkspaceRunModeMenutonull. +6 lines, one file, nosrc/changes.Why CI did not catch it
PR CI (
.github/workflows/ci-tests.yml→openwork-tests-core) only runspnpm test:core, a hand-picked list of 18 app test files that does not include this one. The fullpnpm --filter @openwork/app testonly runs inopenwork-tests-extended, which is gated toschedule(nightly 07:37 UTC) andworkflow_dispatchand does not block PRs. So this red has been visible only in the nightly since #4293 (Sep 5).Evidence
Daytona lane (matching E2E spec, run on PR head; published in the sticky test-evidence comment below):
This proves the product behavior the unit test covers is intact on the real desktop app, supporting the "test drift, not regression" classification.
Local lane (bun unit tests; there is no testkit wrapper for
apps/appunit tests):Target test on PR head
f2629144f:Full app unit suite, PR head vs clean
origin/devcontrol (same command, same bun 1.4.0 / pnpm 11.4.0 / node 24.20.0):The only difference in the failing set is this test going green. The suite exit is still 1 because of the pre-existing reds below.
Other pre-existing reds (not fixed here — separate ownership)
Identical on clean
origin/devand this branch (19 tests, 8 files):tests/message-list-loading.test.tsxPlatform context is missing— same root cause as #4650, needsPlatformProvidertests/message-list-step-fold.test.tsxPlatform context is missing— same root cause as #4650tests/command-palette-settings.test.tsexpect(...).toBe / toEqualtests/app-mentions.test.tsexpect(...).toContaintests/managed-brand-header.test.tsexpect(...).not.toContaintests/prompt-file-parts.test.tsexpect(...).toEqualtests/tool-error-attribution-ui.test.tsxexpect(...).toContaintests/mcp-local-server-recovery.test.tsComputer Use requires the bundled OpenWork helper on macOS.(likely macOS-env only)The 13
message-list-*failures are the samePlatformProviderdrift from #4650 and are a natural follow-up, kept out of this PR to keep the diff minimal.Verdict
Passed for the claim in scope (this test is green on the PR head; no
src/change). The full-suite command is still red ondevfor the pre-existing failures listed above.