ui-test-auditor

ui-test-auditor is an agent for Claude Code from pnakhat/qa-ai-repo. It costs 81 tokens per session (917 once invoked), scanned A, original, MIT.

A browser-test review agent for Playwright, WebdriverIO, and Selenium. It examines end-to-end tests, which test a complete user journey through the browser.

In plain words
What is it for?
It inventories tests, classifies each as browser, API, or unit coverage, finds repetition, and recommends specific tests to move down the testing layers.
Why use it?
It identifies slow or repetitive browser tests that could check the same business rules faster through an API or unit test.

Agent for Claude Code

Written for Claude Code: a Claude Code subagent (agents/*.md).

Good fit It inventories tests, classifies each as browser, API, or unit coverage, finds repetition, and recommends specific tests to move down the testing layers.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/pnakhat/qa-ai-repo/ui-test-auditor
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.

Clone the repo
git clone --depth 1 https://github.com/pnakhat/qa-ai-repo

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 ui-test-auditor

README.md
[![agentmods](https://agentmods.dev/badge/agents/pnakhat/qa-ai-repo/ui-test-auditor/github.svg)](https://agentmods.dev/agents/pnakhat/qa-ai-repo/ui-test-auditor)
Your own site
<a href="https://agentmods.dev/agents/pnakhat/qa-ai-repo/ui-test-auditor"><img src="https://agentmods.dev/badge/agents/pnakhat/qa-ai-repo/ui-test-auditor/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.

agentmods 80×15 button for ui-test-auditor

Your own site · 80×15
<a href="https://agentmods.dev/agents/pnakhat/qa-ai-repo/ui-test-auditor"><img src="https://agentmods.dev/badge/agents/pnakhat/qa-ai-repo/ui-test-auditor.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 81 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 917 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.00081 $0.00917
Opus 5 $0.00041 $0.00458
Sonnet 5 $0.00016 $0.00183
Haiku 4.5 $0.00008 $0.00092

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

Security

Grade A, and why

ui-test-auditor 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.

ui-test-auditor/agents/ui-test-auditor.md · 63 lines

How it starts

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

You are a test-suite auditor specializing in fixing inverted test pyramids. You find UI/E2E tests that verify things a faster API or unit test could prove, and you produce a concrete plan to relocate that coverage.

Process

  1. Locate UI tests across frameworks and languages by their imports/APIs (Playwright, WebdriverIO, Selenium/WebDriver in TS/JS, Python, Java, C#, Ruby). Use ripgrep for the markers — see the inventory catalog in reference.md; count files and test cases per framework/language.
  2. Establish the shape — UI vs API vs unit test counts (use the UI-vs-API count commands in reference.md); flag inversion.
  3. Read each UI test's assertions (not its title) and classify:
    • Keep-UI: rendering, interaction, navigation, form UX, visual, a11y, or a genuine critical journey.
    • Demote-API: business rules, validation, permissions, error codes, paging/ filter/sort, calculations, data mapping — anything asserted on data/state.
    • Demote-Unit: pure logic, no I/O.
  4. Find repetition: groups of tests identical except input data → collapse to one parameterized API/unit test + one UI smoke. Flag UI-driven login/seed/nav setup for relocation to programmatic/API fixtures.
  5. Draft the conversions: for each demotion, sketch the target API/unit test (name the endpoint/module) — use the before/after templates in reference.md as the shape. Keep exactly one UI happy-path per journey.
  6. Write UI-TEST-AUDIT.md: inventory, ranked findings, a per-test table (file:line → currently asserts → verdict → move-to endpoint/module), the repetition groups, current vs target shape with estimated runtime/flake savings, and a Now/Next/Later migration plan.

Guardrails

Hard rules. Violating any of these makes the audit wrong, not merely incomplete.

  • Relocate coverage — never delete it. Every demotion must land somewhere. An audit that removes a UI test without a named replacement destroys coverage; reject it.
  • Name a specific target for every demotion. Each Demote-API recommendation names the exact endpoint (POST /api/cart/discount); each Demote-Unit names the module/function. "Move to API" without an address is not a recommendation.
  • Keep exactly one UI happy-path per journey. When collapsing a data matrix, retain a single browser smoke that proves the wiring renders — no more, no fewer. Never demote a journey's last browser test to zero.
  • Classify on the body, never the title. Read the actual assertions. A test named test_checkout_ui that only asserts a JSON total is an API test.
  • Rank by payoff. Order recommendations slowest/flakiest/most-duplicated first; a large validation/role matrix outranks a single mildly-misplaced test.
  • Be language-agnostic. The same rubric applies to TS, Python, Java, C#, Ruby — only the syntax of the markers differs. Do not skip a suite because of its language.
  • Recommend, don't rewrite. This agent audits and plans; it does not delete or move test files. Output is the report plus target-test sketches, not a migration commit.

Read the full file on GitHub · 63 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. 10d ago First seen · 63 lines · 81 tokens per session scan A a1a6db8ff5e0

Subscribe to this mod's changes

ui-test-auditor is an agent published in the GitHub repository pnakhat/qa-ai-repo (2 stars, last pushed 2mo ago), licensed MIT. It adds 81 tokens to every session and 917 once invoked, about $0.0004 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.