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 saajunaid/caddis-plugin --skill component-testinggit clone --depth 1 https://github.com/saajunaid/caddis-pluginWrote 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/saajunaid/caddis-plugin/component-testing)<a href="https://agentmods.dev/skills/saajunaid/caddis-plugin/component-testing"><img src="https://agentmods.dev/badge/skills/saajunaid/caddis-plugin/component-testing/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/saajunaid/caddis-plugin/component-testing"><img src="https://agentmods.dev/badge/skills/saajunaid/caddis-plugin/component-testing.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.00050 | $0.02556 |
| Opus 5.5 | $0.00020 | $0.01022 |
| Sonnet 5.5 | $0.00010 | $0.00511 |
| Haiku 4.5 | $0.00005 | $0.00256 |
Grade A, and why
component-testing 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 2mo 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 — 311 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Component Testing Skill
React component and hook testing with Vitest + Testing Library. For E2E tests, use the playwright skill. For methodology, use tdd-workflow. This skill covers unit and integration testing of components.
1. Vitest Setup
vite.config.ts
import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
export default defineConfig({
plugins: [react()],
test: {
environment: 'jsdom', // or 'happy-dom' (faster, less spec-compliant)
globals: true, // No need to import describe/it/expect
setupFiles: ['./src/test/setup.ts'],
coverage: {
provider: 'v8',
reporter: ['text', 'html', 'lcov'],
include: ['src/**/*.{ts,tsx}'],
exclude: ['src/**/*.stories.*', 'src/test/**'],
thresholds: { lines: 80, functions: 80, branches: 70 },
},
},
})
src/test/setup.ts
import '@testing-library/jest-dom' // Adds toBeInTheDocument(), toHaveValue(), etc.
import { cleanup } from '@testing-library/react'
import { afterEach, beforeAll, afterAll } from 'vitest'
import { server } from './msw/server' // MSW server (if using)
beforeAll(() => server.listen({ onUnhandledRequest: 'error' }))
afterEach(() => { cleanup(); server.resetHandlers() })
afterAll(() => server.close())
2. Testing Library — Query Priority
Use queries from most to least accessible:
| Priority | Query | Why |
|---|---|---|
| 1 | getByRole |
Tests semantic HTML + ARIA — closest to real user experience |
| 2 | getByLabelText |
Tests forms with labels — accessibility signal |
| 3 | getByPlaceholderText |
Acceptable for inputs without labels |
| 4 | getByText |
Tests text content |
| 5 | getByDisplayValue |
Tests current input/textarea/select value |
| 6 | getByAltText |
Tests image alt text |
| 7 | getByTitle |
Low priority — title attributes are often hidden |
| Avoid | getByTestId |
Last resort only — no accessibility signal |
// ✅ GOOD: Role + accessible name
const button = screen.getByRole('button', { name: /save changes/i })
// ✅ GOOD: Label association
const emailInput = screen.getByLabelText(/email/i)
// ❌ AVOID unless no alternative
const element = screen.getByTestId('submit-btn')
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.
- 2mo ago Changed · -29 tokens per session f6cd50c96fa4
- 2mo ago First seen · 311 lines · 79 tokens per session scan A f9367ac7561a
component-testing is a skill published in the GitHub repository saajunaid/caddis-plugin (0 stars, last pushed 3d ago), licensed MIT. It adds 50 tokens to every session and 2,556 once invoked, about $0.0002 per session on Opus 5.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-09-03.
component-testing compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| component-testingsaajunaid/caddis-plugin | Skill | 0 | 3d ago | MIT | A | 50 | Claude Code |
| agent-testerruvnet/ruflo | Skill | 83k | today | MIT | A | 15 | Claude Code |
| test-generatoralirezarezvani/claude-code-tresor | Skill | 790 | 20d ago | MIT | A | 55 | Claude Code |
| goga-cookbookqarium/goga | Skill | 46 | 8d ago | BSD-3-Clause | A | 19 | Claude Code, Codex |
| goga-review-planqarium/goga | Skill | 46 | 8d ago | BSD-3-Clause | A | 11 | Claude Code, Codex |
| goga-define-challengeqarium/goga | Skill | 46 | 8d ago | BSD-3-Clause | A | 6 | Claude Code, Codex |
| goga-task-by-specifyingqarium/goga | Skill | 46 | 8d ago | BSD-3-Clause | A | 14 | Claude Code, Codex |