# MCP App Test

> Test MCP Apps across hosts. Server API tests, Playwright E2E, cross-host validation, and debugging with ui-inspector. WHEN: 'test my MCP App', 'write tests for MCP server', 'cross-host testing', 'debug MCP App iframe', 'Playwright MCP tests', 'why is my MCP App broken', 'validate across hosts'.

- Skill: `dc995/mcp-app-test` (Agent Skill, multi-file: 6 files)
- Install (CLI): `npx skillmds@latest add dc995/mcp-app-test`
- Raw SKILL.md: https://api.skillmd.com/api/skills/dc995/mcp-app-test/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: dc995 (https://skillmd.com/u/dc995)
- Updated: 2026-09-22
- Page: https://skillmd.com/skills/dc995/mcp-app-test

---


# MCP App Test

Multi-layer test strategy for MCP Apps: protocol-level server tests, browser E2E, and cross-host validation.

## Test Layers

| Layer | What | Browser? | Speed | Catches |
|---|---|---|---|---|
| **Server API** | MCP protocol, tool schemas, resource serving | No | Fast | Regressions in tool logic, broken resources, schema changes |
| **E2E** | Full rendering, iframe bridge, UI interactions | Yes | Medium | CSS/layout, postMessage, iframe initialization failures |
| **Cross-Host** | Same app in multiple hosts, compare results | Yes | Slow | Host-specific CSP, permission, rendering differences |

## Sub-Files

| File | Purpose |
|---|---|
| [server-api.md](server-api.md) | Layer 1: MCP protocol tests (no browser) |
| [e2e.md](e2e.md) | Layer 2: Playwright E2E patterns (page objects, fixtures) |
| [cross-host.md](cross-host.md) | Layer 3: Multi-host validation matrix |
| [debugging.md](debugging.md) | ui-inspector, DevTools, postMessage tracing |
| [references/playwright-patterns.md](references/playwright-patterns.md) | Generic fixtures + helpers distilled from a multi-app validation suite |

For new protocol tests, default to MCP `2026-07-28`: prove self-contained
requests, `server/discover`, routing headers, cache scope, MRTR, and explicit
application handles. Keep `initialize`/`Mcp-Session-Id` fixtures in a separately
named legacy compatibility suite.

## Quick Start

### Run the target project's existing tests
```bash
cd tests
npm test                    # use scripts already defined by the target project
```

### Prerequisites
Start only the servers required by the selected tests. Prefer test fixtures or
workspace tasks that own process startup and teardown rather than assuming a
specific repository launcher.

