Skip to content

[codex] test ErrorBoundary fallback recovery#68

Draft
prettyboyvic wants to merge 1 commit into
Grainlify:mainfrom
prettyboyvic:test/error-boundary
Draft

[codex] test ErrorBoundary fallback recovery#68
prettyboyvic wants to merge 1 commit into
Grainlify:mainfrom
prettyboyvic:test/error-boundary

Conversation

@prettyboyvic

Copy link
Copy Markdown

Summary

  • add component tests for ErrorBoundary fallback rendering, theme classes, reset recovery, guarded logging, and production-safe details
  • route caught errors through the shared guarded logger instead of raw console.error
  • make the reset action recover the boundary without forcing a page reload
  • restore Vitest's node_modules exclusion so the app test script does not collect dependency test files

Validation

  • corepack pnpm@9.15.9 install --frozen-lockfile
  • corepack pnpm@9.15.9 exec vitest run src/shared/components/ErrorBoundary.test.tsx (5 tests passed)
  • corepack pnpm@9.15.9 test (16 files / 197 tests passed; existing jsdom stderr remains from current AuthContext and Leaderboard tests)
  • corepack pnpm@9.15.9 exec prettier --check vite.config.ts src/shared/components/ErrorBoundary.tsx src/shared/components/ErrorBoundary.test.tsx
  • corepack pnpm@9.15.9 exec eslint src/shared/components/ErrorBoundary.tsx src/shared/components/ErrorBoundary.test.tsx (0 errors; existing Fast Refresh warning on ErrorBoundary export shape)

Notes

  • npm ci is blocked by the stale package-lock.json, so validation used the committed pnpm-lock.yaml with pnpm 9.
  • corepack pnpm@9.15.9 typecheck cannot run because tsc is not installed in the project dependencies.

Closes #38

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add component tests for ErrorBoundary themed fallback and recovery reset

1 participant