CtrlK
BlogDocsLog inGet started
Tessl Logo

testland/msw-handlers

Authors Mock Service Worker (MSW) request handlers for both browser and Node.js test environments using the `http.get` / `http.post` / `HttpResponse.json` API, wires them via `setupWorker` (browser) or `setupServer` (Node), and manages the test lifecycle (`server.listen` / `resetHandlers` / `close`). Use when the project uses JavaScript / TypeScript and needs to mock fetch / XHR at the network layer for both Vitest / Jest unit tests and Cypress / Playwright integration tests.

92

Quality

92%

Does it follow best practices?

Impact

Average score across 10 eval scenarios

SecuritybySnyk

Passed

No findings from the security scan

Overview
Quality
Evals
Security
Files

Quality

Content

82%Weight 40%Scale 1-5

Reviews the quality of instructions and guidance provided to agents. Good implementation is clear, handles edge cases, and produces reliable results.

A dense, actionable SKILL.md with copy-paste-ready code and well-structured tables, sequenced as a clear workflow; its chief weakness is mild verbosity and inline content that could be progressively disclosed into reference files.

Suggestions

Consolidate the repeated '(Per [msw-getting-started][gs].)' citations into a single note under References to trim redundant tokens.

Move the HttpResponse static-helpers and pattern-matching tables into a `references/api.md` and link from the body, improving progressive disclosure.

Add an explicit verify step (e.g. 'run a single test to confirm handlers intercept before running the full suite') to close the workflow feedback loop.

DimensionReasoningScore

Conciseness

Largely lean and assumes JS competence, but the repeated '(Per [msw-getting-started][gs].)' citations and a brief Service-Worker explanation in the Overview are minor padding that could be trimmed; not a 5 because not every token earns its place.

4 / 5

Actionability

Fully executable, copy-paste-ready code for handlers.js, browser.js, node.js, the Vitest/Jest setup, per-test overrides, and CI yaml, plus concrete HttpResponse-helper and pattern-matching tables covering the common cases.

5 / 5

Workflow Clarity

Clear install→author→browser/node setup→lifecycle sequence with an explicit hooks table, and `onUnhandledRequest: 'error'` acts as a validation checkpoint; just shy of 5 because there is no explicit verify/retry feedback loop around the mock setup itself.

4 / 5

Progressive Disclosure

Well-organized with clear section headers and only one-level-deep (external) references, but substantial inline content (HttpResponse helpers, pattern matching, the anti-patterns table) that could be split into reference files keeps it just below 5; no bundle files exist to offload it.

4 / 5

Total

17

/

20

Passed

Description

100%Weight 40%Scale 1-5

Based on the skill's description, can an agent find and select it at the right time? Clear, specific descriptions lead to better discovery.

A highly specific, third-person description with concrete API names, a synonym-rich trigger vocabulary, and an explicit 'Use when' clause that cleanly distinguishes it from sibling mocking skills.

DimensionReasoningScore

Specificity

Lists multiple concrete actions tied to named APIs — authoring handlers via `http.get`/`http.post`/`HttpResponse.json`, wiring via `setupWorker`/`setupServer`, and managing the `server.listen`/`resetHandlers`/`close` lifecycle — covering both environments comprehensively.

5 / 5

Completeness

Explicitly answers both 'what' (authors/wires/manages the handler lifecycle) and 'when' via a concrete 'Use when the project uses JavaScript / TypeScript and needs to mock fetch / XHR…' trigger clause.

5 / 5

Trigger Term Quality

Comprehensive natural-term coverage including the synonym pair 'MSW'/'Mock Service Worker', 'mock fetch/XHR', 'JavaScript/TypeScript', and the full set of test frameworks (Vitest/Jest/Cypress/Playwright) a user would actually name.

5 / 5

Distinctiveness Conflict Risk

Occupies a clear niche (MSW network-layer mocking for JS/TS test environments) and even contrasts with the JVM `wiremock-stubs` skill, giving minimal conflict risk.

5 / 5

Total

20

/

20

Passed

Validation

93%

Checks the skill against the spec for correct structure and formatting. All validation checks must pass before discovery and implementation can be scored.

Validation15 / 16 Passed

Validation for skill structure

CriteriaDescriptionResult

referenced_paths_exist

Referenced path issues: 1 missing

Warning

Total

15

/

16

Passed

Reviewed

Table of Contents