test(e2e): cover unified DashboardContainer (collapse, border, tabs, drag)#2205
test(e2e): cover unified DashboardContainer (collapse, border, tabs, drag)#2205alex-fedotyev wants to merge 1 commit intomainfrom
Conversation
…drag) PR #2015 unified the legacy section/group concept into a single DashboardContainer with collapsible / bordered / tabs / drag-to-reorder plus URL-state persistence. Unit tests landed with #2015; this PR adds the missing E2E coverage that Drew called out in his top-level review. What this covers: - Default collapsible chevron + bordered style on a new group. - Toggling Hide Border / Show Border via the overflow menu. - Adding a tab so the tab bar appears, switching tabs updates ?activeTabs and aria-selected. - ?collapsed and ?expanded URL params survive reload. - ?activeTabs URL param survives reload and restores the active tab. - Save-and-reload round-trip preserves containers, bordered=false, and the second tab on group B. - Drag-to-reorder: drag-onto-self is a no-op (DnD guard); dragging A onto C in [A, B, C] yields [B, C, A] (arrayMove semantics) and the new order persists across navigation. Side fixes: - DashboardPage.ts page-object selector updated from the stale add-new-section-menu-item to add-new-group-menu-item (renamed by PR #2015 in DBDashboardPage.tsx); helper renamed addSection -> addGroup. - DashboardContainer.tsx adds data-testid="group-add-tab-\${id}" on the existing Add Tab menu item so the spec does not have to rely on Mantine menu text. No API or schema change. Test-only plus one data-testid line. Tracker: Nerve task 2026-05-04-hyperdxiohyperdx-e2e-tests-for-unifie Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
|
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
🔵 Tier 2 — Low RiskSmall, isolated change with no API route or data model modifications. Why this tier:
Review process: AI review + quick human skim (target: 5–15 min). Reviewer validates AI assessment and checks for domain-specific concerns. Stats
|
|
{"review": "\n## PR Review\n\n✅ No critical issues found.\n\nThis is a clean, well-scoped E2E follow-up to PR #2015. Source change is minimal (one |
E2E Test Results❌ 3 tests failed • 161 passed • 3 skipped • 1215s
Tests ran across 4 shards in parallel. |
Summary
Follow-up E2E coverage for PR #2015 (the unified
DashboardContainerthat replaced the legacy section/group concept). Drew explicitly asked
for this in his top-level review on #2015 ("Can you confirm we have
followup issues/tickets covering... 2. New E2E tests covering the new
functionality"). Unit coverage landed in #2015 itself; this PR adds
the missing browser-level coverage.
The container UX has four moving pieces, all exercised here:
collapsible (chevron + URL state), bordered (overflow-menu toggle +
inline border style), tabs (tab bar appearance, tab switching, URL
state), and drag-to-reorder via @dnd-kit. Each test step cites the
source line that defines the behavior so a reviewer can double-check
the assertion matches the implementation.
Test cases
chevron toggles
aria-expanded.inline border style and the menu label.
switching tabs updates
?activeTabsandaria-selected.?collapsedand?expandedURL params survive reload and restoreper-viewer state.
?activeTabsURL param survives reload and restores the activetab.
bordered=falsestate on group A, and the second tab on group B.DashboardDndContext.tsx:67-70); dragging A onto C in[A, B, C]yields
[B, C, A](arrayMove semantics) and the new orderpersists across navigation.
Side fixes pulled in
DashboardPage.tspage-object selector was still pointing at thestale
add-new-section-menu-itemtestid; PR refactor: Unify section/group into single Group with collapsible/bordered options #2015 renamed it toadd-new-group-menu-item. No existing spec exercisedaddSection,so this hadn't surfaced. Renamed the locator and the helper from
addSection->addGroup.DashboardContainer.tsxaddsdata-testid="group-add-tab-\${id}"on the existing Add Tab menu item so the spec doesn't have to
match Mantine menu text. One-line non-behavior change.
Tier
Predicted Tier 2 by the local classifier: 1 production file,
10 production lines (the testid addition), no API/router/model
touch, single-layer (
packages/app/). Test files are excluded fromthe tier calculation per the classifier rules.
Out of scope
dashboardSections.test.tsxunit tests).DashboardContainer.test.tsx).type: "section"migration (one-time data shape; coveredby
dashboardSections.test.tsx).react-grid-layout, not the new@dnd-kitcontainer DnD).Test plan
yarn lintclean.yarn tsc --noEmitclean.npx playwright test --list tests/e2e/features/dashboard-container.spec.tslists all 7 cases.prose-lintclean againstorigin/main.Refs PR #2015.