frontend-testing

frontend-testing is a skill for Claude Code from sukirman1901/frontend-expert. It costs 62 tokens per session (540 once invoked), scanned A, original, MIT.

A guide for testing what users see and do in a web interface. It explains test-driven development, or TDD, where you write a failing test, make it pass, and then improve the code.

In plain words
What is it for?
Use it for component tests, user-flow tests, accessibility checks, and a small number of full browser tests. It covers loading, error, empty, keyboard, submit, and critical-path behavior.
Why use it?
It catches broken interface behavior and helps prevent bugs from returning. It focuses testing effort on common component states and important user actions.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the frontend-expert plugin — 25 skills, 5 commands, 3 agents, 2 hooks shipped together

Good fit Use it for component tests, user-flow tests, accessibility checks, and a small number of full browser tests. It covers loading, error, empty, keyboard, submit, and critical-path behavior.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/sukirman1901/frontend-expert/frontend-testing
Install

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.

Any agent
npx skills add sukirman1901/frontend-expert --skill frontend-testing
Clone the repo
git clone --depth 1 https://github.com/sukirman1901/frontend-expert

Made for: Claude Code.

Or install frontend-expert, the plugin that ships this one along with the rest of its 25 skills, 5 commands, 3 agents, 2 hooks.

Wrote 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.

agentmods badge for frontend-testing

README.md
[![agentmods](https://agentmods.dev/badge/skills/sukirman1901/frontend-expert/frontend-testing.svg)](https://agentmods.dev/skills/sukirman1901/frontend-expert/frontend-testing)
Your own site
<a href="https://agentmods.dev/skills/sukirman1901/frontend-expert/frontend-testing"><img src="https://agentmods.dev/badge/skills/sukirman1901/frontend-expert/frontend-testing.svg" alt="Measured on agentmods" height="20"></a>
Per session 62 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 540 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00062 $0.00540
Opus 5 $0.00031 $0.00270
Sonnet 5 $0.00012 $0.00108
Haiku 4.5 $0.00006 $0.00054

Measured 8d ago against content hash 0a536e02c104, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

frontend-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 8d 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.

skills/frontend-testing/SKILL.md · 63 lines

What it actually says

Frontend Testing

Overview

Prove UI behavior with a lean pyramid: mostly unit/component tests, some integration, few E2E. Prefer Testing Library queries that mirror how users interact. Include accessibility checks for interactive UI.

When to Use

  • /test-ui or explicit test requests
  • After /ui when the user wants TDD or coverage for a component
  • Fixing a UI bug (regression test first)

Workflow

  1. Choose level

    • Unit/component (~80%): render, props, states (loading/error/empty)
    • Integration (~15%): user flows across a few components
    • E2E (~5%): critical paths only (Playwright/Cypress)
  2. TDD when changing behavior

    • Red → Green → Refactor
    • One behavior per test; name by user-visible outcome
  3. Query priority (Testing Library)

    • Prefer: role, label, text
    • Avoid: test IDs unless no accessible name exists
  4. Must cover for interactive UI

    • Default render
    • Loading / error / empty when those states exist
    • Primary user action (click/submit)
    • Keyboard path for custom controls when non-native
    • Robustness (when risk is real): double-submit / spam click, interrupt open→close mid-animation, slow network loading UI
  5. Accessibility in tests

    • axe-core (or equivalent) on critical components when tooling exists
    • Assert accessible names on icon-only controls
  6. Visual regression (optional)

    • Storybook + Chromatic/Percy when the project already uses them
    • Do not introduce a visual stack just for this skill

Checklist

  • Tests describe user-visible behavior
  • Loading / error / empty covered when applicable
  • Double-submit / interrupt paths covered when destructive or async
  • No unnecessary test-id queries
  • Regression test for bugs fixed
  • A11y assertion or axe run for interactive surfaces (when tooling available)

Depth

Full guide: references/testing.md. Robustness ideas also in references/anti-patterns.md.

Changes

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.

  1. 8d ago First seen · 63 lines · 62 tokens per session scan A 0a536e02c104

Subscribe to this mod's changes

frontend-testing is a skill published in the GitHub repository sukirman1901/frontend-expert (10 stars, last pushed 4d ago), licensed MIT. It adds 62 tokens to every session and 540 once invoked, about $0.0003 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.

Related

Other skills, from other repositories

react-web

React web development with hooks, React Query, Zustand.

alinaqi/maggy · 13 tokens

review-screenshot

A standard workflow for taking screenshots to check a user interface, using a dedicated review process for different verification modes.

YuDefine/nuxt-supabase-starter · 75 tokens

web-dev-standards

Use when designing software architectures ('codebase-design' Deep Modules/Design-It-Twice), writing tests ('test-driven-development' mock boundaries), creating setup scripts ('interactive-wizard'), TypeScript standards, Next.js, Expo, or Monorepos.

J-StaR-Films-Studios/VibeCode-Protocol-Suite · 57 tokens

fec-tdd-workflow

A frontend test-driven development workflow, or TDD, describes the expected behavior with a failing test, implements the smallest change to pass it, and then refactors. It covers UI components, hooks, API clients, route guards, and user workflows.

bovinphang/frontend-craft · 80 tokens

figma-to-react-workflow

Orchestrates end-to-end Figma-to-React conversion pipeline with enforced TDD, automated pixel-diff visual QA, E2E testing, and app-type awareness (web apps, Chrome extensions, PWAs). Keywords: Figma to React, design tokens, autonomous component generation, Figma conversion, Tailwind config, component library, TDD…

PMDevSolutions/Aurelius · 85 tokens

tdd-from-figma

Writes failing tests FIRST from Figma structure and the design token lockfile, then implementation makes them pass. Per-component TDD cycle using exact values from design-tokens.lock.json. App-type-aware: generates Chrome extension, PWA, and web app test templates. Keywords: TDD, test-driven development, Figma tests…

PMDevSolutions/Aurelius · 92 tokens