test: Comprehensive E2E test suite — full CDP click-through coverage#61
Merged
test: Comprehensive E2E test suite — full CDP click-through coverage#61
Conversation
…click-only navigation - Delete 9 old spec files that used programmatic navigation (pushState, location.hash) - Rewrite helpers/navigation.ts with click-only patterns (real sidebar button clicks) - Create helpers/page-helpers.ts with shared interaction patterns (tabs, modals, forms) - Update electron.setup.ts with dotenv loading for .env.test credentials Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Covers login page rendering, empty form submission validation, register link navigation, register page fields, back-to-login navigation, Hub setup link presence, successful login with redirect to dashboard, and console error assertions. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
10 tests covering all dashboard widgets: - Dashboard loads after login, greeting header, QuickCapture CRUD, RecentProjects, DailyStats, ActiveAgents, error boundary check, and console error monitoring. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Covers Alerts page (tabs, create modal open/close, alert actions) and Communications page (Overview/Slack/Discord/Rules tabs, panel content, non-blank rendering). Uses authenticatedWindow fixture and console error collector. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
02-navigation-sweep.spec.ts — 12 tests covering every top-level sidebar nav item click, Settings click, full sequential sweep with console error assertion, and page content verification. 03-sidebar-mechanics.spec.ts — 9 tests covering sidebar visibility, collapse/expand toggle, active state highlighting, active state change on navigation, Settings footer placement, sidebar persistence across pages, project-scoped items disabled state, and console error checks. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Covers page load, interactive elements, content states, and console error checks for the three content pages (05-briefing, 06-my-work, 07-notes). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
13-global-overlays.spec.ts covers: - CommandBar: visible in TopBar, accepts text, Escape clears/blurs, Ctrl+K focuses, no console errors - Assistant Widget: FAB visible, click opens panel, chat input visible, type in chat, close via button, Ctrl+J toggle, no console errors Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
19 tests covering all Settings page sections: - Navigation to settings via sidebar footer - Appearance mode toggling (Light/Dark/System) - Color theme switching (Ocean, Forest, Oscura default) - data-theme attribute verification on html element - UI Scale range input visibility - Typography font family dropdown and font size slider - Language section (English) - Hub Connection section - Profiles section - Storage Management section - About section with ADC version - Reset defaults (Dark + Oscura) - Console error sweep during interaction Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Covers 08-personal-tools.spec.ts with three describe blocks: - Fitness: page load, tab visibility, tab switching, Log Workout button, no console errors - Planner: page load, date nav, Day/Week toggle, Today button, Weekly Review navigation, back to Daily, no console errors - Productivity: page load, tab visibility, tab switching, no console errors All navigation via real sidebar clicks using authenticatedWindow fixture. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
12 tests covering TopBar navigation to projects, page header, Init Wizard and Create Project wizard open/close, step indicators, empty/populated project list states, project row click navigation, TopBar project tabs, and console error assertions. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Single sequential canary test that walks the entire app: - Dashboard verification after login - All 9 top-level sidebar nav items with URL + content checks - Projects list via TopBar, open first project if available - All 9 project-scoped sidebar items (conditional on project) - Settings with Ocean/Oscura theme switching - Keyboard shortcuts (Ctrl+K CommandBar, Ctrl+J Assistant) - Return to Dashboard, assert clean console Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Verifies computed style changes across theme and mode switches: - Default dark mode (class="dark", no data-theme) - Ocean theme sidebar background differs from default - Forest theme card background differs from Ocean - Light mode body background differs from dark mode - Dark mode restores correctly after toggling - Reset defaults (Oscura + dark) removes data-theme - No console errors during full theme cycle Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…ec.ts Covers all 9 project-scoped pages (Tasks, Terminals, Agents, Pipeline, Roadmap, Ideation, GitHub, Changelog, Insights) with graceful empty-state handling and console error assertion. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Add screenshot helper (tests/e2e/helpers/screenshot.ts) with takeScreenshot() and takeFullPageScreenshot() functions - Add 13 screenshot captures across 5 E2E test files at visual checkpoints: sidebar states, dashboard layout, theme switching, light/dark modes, and smoke flow milestones - Add post-e2e-screenshots.sh script that commits screenshots and posts an image gallery to the PR description via gh CLI - Add test:e2e:report npm script combining test run + gallery post - Add tests/e2e/screenshots/ to .gitignore (force-added on branches) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Electron production builds serve the renderer via file:// protocol, which doesn't support browser pushState history. Switch TanStack Router to createHashHistory() so routes resolve correctly in packaged builds. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…r theme var - RootLayout: change Panel minSize from "56px" to "160px" so expand() reveals labels - Sidebar: use bg-sidebar text-sidebar-foreground instead of bg-card for proper theme variable usage - Update FEATURES-INDEX.md and user-interface-flow.md to reflect sidebar changes Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…+ viewport overrides Add --ag-data-background-color (critical for dark mode data viewport), --ag-secondary-border-color, --ag-input-border-color, text variables, panel/menu variables, color-scheme: dark for native scrollbars, and explicit .ag-root-wrapper/.ag-body-viewport background fallbacks. Update ai-docs/PATTERNS.md AG-Grid theming section with full variable catalog and dark mode rules. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Replace __dirname (not available in ESM) with dirname(fileURLToPath(import.meta.url)). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The initial CSS variable overrides were being defeated by Tailwind v4's CSS layer ordering. Added !important to all AG-Grid container background declarations and expanded coverage to every internal element (root-wrapper, root-wrapper-body, root, body, body-viewport, center-cols-viewport, center-cols-container). Also added bg-card Tailwind utility on the wrapper div as belt-and-suspenders. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Captures 6 screenshots via CDP WebSocket: - Dashboard with expanded sidebar - Dashboard with collapsed sidebar (icon-only) - Sidebar re-expanded - AG-Grid task view with detail row - Settings page - Dashboard initial state Also adds scripts/capture-screenshots.mjs for future captures. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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.
Summary
page.evaluate()for navigation, zeropushState, zero programmatic routingnavigation.ts(click-only nav),page-helpers.ts(interaction patterns)scripts/post-e2e-screenshots.sh) that commits screenshots and posts an image gallery to the PR descriptionBug Fixes (3 critical UI issues)
Fix 1: Production Routing — Hash History
pushState()by default. Electron production builds load viafile://protocol where pushState doesn't work, causing "Not Found" on every route.createHashHistory()from TanStack Router. URLs now use/#/pathformat which works on bothfile://andhttp://protocols.src/renderer/app/router.tsxFix 2: Sidebar Expand/Collapse
react-resizable-panelsPanel hadminSize="56px"matchingcollapsedSize="56px", sopanel.expand()expanded to the minimum which looked identical to collapsed. Also usedbg-cardinstead ofbg-sidebar.minSizeto"160px"creating proper gap between collapsed (56px) and minimum expanded (160px). Switched tobg-sidebar+text-sidebar-foreground.src/renderer/app/layouts/RootLayout.tsx,src/renderer/app/layouts/Sidebar.tsxFix 3: AG-Grid Dark Mode Theming
--ag-data-background-color,--ag-secondary-foreground-color, etc.),color-scheme: darkfor native scrollbar styling, and!importanton explicit background overrides for every AG-Grid internal container element.src/renderer/features/tasks/components/grid/ag-grid-theme.css,TaskDataGrid.tsxTest Files (15)
01-auth.spec.ts02-navigation-sweep.spec.ts03-sidebar-mechanics.spec.ts04-dashboard.spec.ts05-briefing.spec.ts06-my-work.spec.ts07-notes.spec.ts08-personal-tools.spec.ts09-alerts-comms.spec.ts10-project-management.spec.ts11-project-scoped-pages.spec.ts12-settings-full.spec.ts13-global-overlays.spec.ts14-theme-visual.spec.ts15-smoke-flow.spec.tsVerification
Test plan
npm run test:e2ewith.env.testcredentials to execute the full suite🤖 Generated with Claude Code
E2E Screenshots (After Fixes)
Dashboard — Expanded Sidebar
Sidebar — Collapsed (Icon-Only)
Sidebar — Re-Expanded
AG-Grid Task View (with Detail Row)
Settings Page