Skip to content

Commit c210272

Browse files
test: move pure core unit tests from react-doctor/tests to core/tests
Per AGENTS.md: 'packages/core/tests/ — service tests + run-inspect orchestration tests; packages/react-doctor/tests/ — CLI + end-to-end fixture tests'. Seven test files were testing pure core helpers from the wrong package (long-standing architectural drift; tests imported from @react-doctor/core to exercise core internals): - dedupe-diagnostics.test.ts - evaluate-suppression.test.ts - errors.test.ts - filter-for-surface.test.ts - find-jsx-opener-span.test.ts - format-error-chain.test.ts - parse-tailwind-major-minor.test.ts These have no CLI dependency, no fixture-directory dependency, and no end-to-end concerns. Move them into packages/core/tests/. Imports keep using @react-doctor/core (core supports self-imports — see the existing tests/run-inspect.test.ts). 74 tests migrated; total test count unchanged (185 + 1478 = 1663 matches the pre-move 111 + 1552 = 1663). Larger fixture-dependent tests (discover-project.test.ts, find-monorepo-root.test.ts, etc.) stay in place for now — moving them requires either moving the fixtures directory or threading parent- relative paths through the tests. Documented as a follow-up. Co-authored-by: Aiden Bai <aidenybai@users.noreply.github.com>
1 parent 9287db0 commit c210272

7 files changed

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

packages/react-doctor/tests/parse-tailwind-major-minor.test.ts renamed to packages/core/tests/parse-tailwind-major-minor.test.ts

File renamed without changes.

0 commit comments

Comments
 (0)