playwright-test-generator

playwright-test-generator is an agent for Claude Code from RaNDoM6913/claude-code-superkit. It costs 17 tokens per session (1,950 once invoked), scanned A, original, MIT.

A Playwright test generator for an administration panel built with React and TypeScript. Playwright is a tool that tests websites in a real browser.

In plain words
What is it for?
Use it to generate browser tests for admin pages such as users, moderation, monetization, settings, roles, and system management.
Why use it?
It reduces the effort of writing repeatable end-to-end tests that verify the admin panel as a user would operate it.

Agent for Claude Code

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.

agentmods
npx agentmods add agents/random6913/claude-code-superkit/playwright-test-generator
Clone the repo
git clone --depth 1 https://github.com/RaNDoM6913/claude-code-superkit

Made for: Claude Code.

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 playwright-test-generator

README.md
[![agentmods](https://agentmods.dev/badge/agents/random6913/claude-code-superkit/playwright-test-generator.svg)](https://agentmods.dev/agents/random6913/claude-code-superkit/playwright-test-generator)
Your own site
<a href="https://agentmods.dev/agents/random6913/claude-code-superkit/playwright-test-generator"><img src="https://agentmods.dev/badge/agents/random6913/claude-code-superkit/playwright-test-generator.svg" alt="Measured on agentmods" height="20"></a>
Per session 17 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,950 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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.00017 $0.01950
Opus 5 $0.00009 $0.00975
Sonnet 5 $0.00003 $0.00390
Haiku 4.5 $0.00002 $0.00195

Measured 2d ago against content hash 21bd33460194, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

playwright-test-generator 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 2d 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.

packages/showcase/.claude/agents/playwright-test-generator.md · 234 lines

How it starts

The opening of the file, as written. The whole thing — 234 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Playwright Test Generator — SocialApp Admin Panel

Generate Playwright e2e tests for the admin frontend panel following SocialApp conventions and Playwright best practices.

Phase 0: Load Project Context

Read if exists:

  1. CLAUDE.md or AGENTS.md — project conventions
  2. docs/architecture/ — relevant architecture docs for the task at hand

Use this context to:

  • Know project-specific conventions and patterns
  • Identify documented rules to check with HIGH confidence
  • Understand the tech stack and framework in use

Project Context

  • Stack: React 19 + TypeScript 5.9 + Vite 7 + Tailwind CSS 3.4 + Radix UI
  • Routing: state-based (activePage in AppShell), NOT React Router
  • API layer: requestJSON<T>() through live-only API clients (*ApiLive.ts + *ApiClient.ts)
  • Test runner: cd adminpanel/frontend && npm run test:e2e
  • Config: adminpanel/frontend/playwright.config.ts (baseURL http://127.0.0.1:4173, Chromium)
  • Existing tests: adminpanel/frontend/tests/admin-smoke.spec.ts
  • Admin pages: Overview, Users, Moderation, Engagement, Monetization, Ads, Settings, Roles & Access, System

Test Patterns

Page Object Model

Every page under test gets a Page Object class. Place them in adminpanel/frontend/tests/pages/.

// tests/pages/users-page.ts
import { type Locator, type Page, expect } from '@playwright/test';

export class UsersPage {
  readonly page: Page;
  readonly heading: Locator;
  readonly searchInput: Locator;
  readonly userTable: Locator;

  constructor(page: Page) {
    this.page = page;
    this.heading = page.locator('header').getByRole('heading', { level: 2, name: 'Users' });
    this.searchInput = page.getByPlaceholder('Search users...');
    this.userTable = page.getByRole('table');
  }

  async navigate() {
    await this.page.locator('aside').getByRole('button', { name: 'Users' }).click();
    await expect(this.heading).toBeVisible();
  }

  async searchUser(query: string) {
    await this.searchInput.fill(query);
    await this.searchInput.press('Enter');
  }
}

Read the full file on GitHub · 234 lines

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. 2d ago First seen · 234 lines · 17 tokens per session scan A 21bd33460194

Subscribe to this mod's changes

playwright-test-generator is an agent published in the GitHub repository RaNDoM6913/claude-code-superkit (2 stars, last pushed 1mo ago), licensed MIT. It adds 17 tokens to every session and 1,950 once invoked, about $0.0001 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-09-03.

Related

Other agents, from other repositories

python-architect

Expert on Python design patterns, modularization, and scalable architecture for the APM CLI codebase. Activate when creating new modules, refactoring class hierarchies, or making cross-cutting architectural decisions.

microsoft/apm · 45 tokens

cdo

APM Chief Documentation Officer. Use this agent as the synthesizer and final arbiter for any multi-persona docs panel -- holds the 3-promise narrative (consume / produce / govern), the chapter-start and chapter-end bridges, the TOC integrity, and the persona ramps (consumer / producer / enterprise). Activate to…

microsoft/apm · 95 tokens

algorithmic-patterns

Load this reference when the PR diff touches code outside the transport/cache layer -- i.e. when the change introduces or modifies loops, data structures, lookup patterns, or module-level imports.

microsoft/apm · 0 tokens

apm-expert

Expert on APM (Agent Package Manager). Helps users install, configure, author, and troubleshoot APM packages, dependencies, compilation, MCP servers, and governance policies.

microsoft/apm · 39 tokens

test-coverage-expert

Test-coverage expert paired with the DevX UX lens. Activate when reviewing PRs that change CLI surface (commands, flags, help text), error wording, exit codes, install/init/run flows, lockfile behavior, auth resolution, hooks, marketplace, or any contract a user can observe -- even when the user does not say "tests"…

microsoft/apm · 151 tokens

auth-expert

Expert on GitHub authentication, EMU, GHE, ADO, and APM's AuthResolver architecture. Activate when reviewing or writing code that touches token management, credential resolution, or remote host authentication.

microsoft/apm · 46 tokens