Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add fubits1/svelte-skills --skill testing-sveltegit clone --depth 1 https://github.com/fubits1/svelte-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/fubits1/svelte-skills/testing-svelte)<a href="https://agentmods.dev/skills/fubits1/svelte-skills/testing-svelte"><img src="https://agentmods.dev/badge/skills/fubits1/svelte-skills/testing-svelte/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/fubits1/svelte-skills/testing-svelte"><img src="https://agentmods.dev/badge/skills/fubits1/svelte-skills/testing-svelte.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00049 | $0.01272 |
| Opus 5 | $0.00024 | $0.00636 |
| Sonnet 5 | $0.00010 | $0.00254 |
| Haiku 4.5 | $0.00005 | $0.00127 |
Grade A, and why
testing-svelte scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 109 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Svelte Testing
Quick Start
// Client-side component test (.svelte.test.ts)
import { render } from "vitest-browser-svelte";
import { expect, test } from "vitest";
import { page } from "vitest/browser";
import Button from "./button.svelte";
test("button click increments counter", async () => {
await render(Button);
const button = page.getByRole("button", { name: /click me/i }); // module page
// or from the result: const screen = await render(Button); screen.getByRole(...)
await button.click();
await expect.element(button).toHaveTextContent("Clicked: 1");
});
Interaction Tests Are Mandatory
Every test for an interactive component MUST include meaningful interaction. A render-only test proves the component mounts, it does NOT prove it works.
For components with inputs, autocompletes, buttons, or forms:
- Interact: click, type, select, submit
- Assert the outcome: the selected value text, the callback data content, the DOM state change
- Never silently skip: no
if (items.length > 0)guards that skip the interaction when the precondition fails. ASSERT the precondition instead. - Verify callback data: use fixture components with data-testid output divs to capture and assert what callbacks received. Checking "callback was called" is not enough; check WHAT it was called with.
Example failure: tests that "verified" autocomplete interaction by checking "a selection exists" without checking which value; this missed a bug where onChange returned objects instead of strings.
Core Principles
- Always use locators:
page.getBy*()methods, never containers - Multiple elements: Use
.first(),.nth(),.last()to avoid strict mode violations - Real API objects: Test with FormData/Request, minimal mocking
- Mock at the right seam:
vi.mockfor module boundaries, MSW for the network boundary. MSW is this rule applied to HTTP: keep the real component and the realfetch, swap only what crosses the wire (svelte-5:msw)
What ships with it
7 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 10d ago First seen · 109 lines · 49 tokens per session scan A bee350768a7f
testing-svelte is a skill published in the GitHub repository fubits1/svelte-skills (10 stars, last pushed 1mo ago), licensed MIT. It adds 49 tokens to every session and 1,272 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
frontend-testing
Comprehensive frontend testing strategy covering unit, integration, E2E, visual regression, and accessibility testing.
test-implement
Implements React/TypeScript unit, integration, and browser E2E tests with the repository's configured runner, mocks, setup, and browser harness. Use when creating or completing frontend tests and generated test skeletons.
angular-testing
Write unit and integration tests for Angular v20+ applications using Vitest or Jasmine with TestBed and modern testing patterns. Use for testing components with signals, OnPush change detection, services with inject(), and HTTP interactions. Triggers on test creation, testing signal-based components, mocking…
angular-testing
Testing Angular 18-21: TestBed, component harnesses (@angular/cdk/testing), Karma+Jasmine (default historical) vs Jest (jest-preset-angular, modern), Angular Testing Library (RTL-style). HttpClient mocking via HttpTestingController. NgRx Effects testing. Cypress / Playwright e2e. Use this skill to: Detect runner…
vue-testing
Testing Vue 3 SPAs: Vitest + @vue/test-utils, RTL-style alternatives, Pinia testing via createTestingPinia, composable testing, msw for network mocks, Cypress component testing, Playwright e2e. Use this skill to: Set up Vitest for Vue 3 with jsdom + @vue/test-utils. Pick mount vs shallowMount. Test components by…
react-testing
Testing React SPAs: React Testing Library + Vitest/Jest for components and hooks, msw for network mocks, Playwright/Cypress for e2e. Query priority, user events, async assertions, mocking patterns. Use this skill to: Pick the right runner (Vitest vs Jest) and setup. Write component tests with RTL using accessible…