Mirror of https://github.com/modelcontextprotocol/inspector — Visual testing tool for MCP servers
  • TypeScript 90.8%
  • JavaScript 8.8%
  • CSS 0.2%
  • HTML 0.2%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Cliff Hall e154378178
fix(coverage): include core/ files in v8 per-file gate (#1301) (#1305)
* fix(coverage): include core/ files in v8 per-file gate (#1301)

Two issues prevented coverage.include's '../../core/...' globs from
reaching core/ files:

1. allowExternal defaults to false — v8 drops any file whose absolute
   path doesn't start with the project root (clients/web/) before the
   include filter runs. Set allowExternal: true, and switch the globs
   to absolute paths so tinyglobby + picomatch handle them correctly.

2. vitest's coverage transformer only processes files inside a project
   root; for everything else it falls back to raw-TS parsing in
   rolldown, which can't handle TS-only syntax (e.g. import type) —
   silently dropping untested core/ files and bypassing the gate.
   Root the unit project at the repo root so the transformer reaches
   core/. The repo root has no node_modules, so add an explicit react
   alias and shift include/setupFiles paths accordingly.

Also add the four pure-type core files (samplingCreateMessage,
sessionStorage, inspectorClientProtocol, inspectorClientEventTarget)
to the exclude list with a comment — they have no executable code.

Verified by introducing an untested probe file, confirming exit=1 with
threshold errors, then removing it.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* refactor(coverage): address review feedback on #1305

- Drop allowExternal: true — with the unit project rooted at repoRoot,
  core/ files are no longer "external" to any project that collects
  coverage (the storybook project doesn't), so the flag is redundant.
- Extract sharedAliases / sharedDedupe constants and reference them
  from both the top-level resolve and the unit project resolve, so
  the two stay in sync if a new core/* alias is added.
- Add TODO(#1243) on the inspectorClientEventTarget.ts exclusion so
  it's revisited once the class gains real behavior in the
  InspectorClient port.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-14 20:17:10 -04:00
.claude Add new components, typography, badge contrast, and screen layout refactors 2026-03-28 20:38:04 -04:00
.github/workflows ci(storybook): wire test:storybook into CI (#1251) (#1297) 2026-05-10 15:58:15 -04:00
clients/web fix(coverage): include core/ files in v8 per-file gate (#1301) (#1305) 2026-05-14 20:17:10 -04:00
core feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
specification docs(apps): specify the v2 Apps tab (#1265) 2026-04-29 17:22:59 -04:00
.gitignore Add .claude/ to .gitignore 2026-04-17 11:57:53 -04:00
AGENTS.md ci(storybook): wire test:storybook into CI (#1251) (#1297) 2026-05-10 15:58:15 -04:00
CLAUDE.md feat: Add Mantine theme, 12 atom components, and 25 molecule components with Storybook stories 2026-03-17 10:23:56 -04:00
package-lock.json feat(apps): add isAppTool helper in core (#1260) (#1272) 2026-05-01 17:03:11 -04:00
package.json ci(storybook): wire test:storybook into CI (#1251) (#1297) 2026-05-10 15:58:15 -04:00