Communitygithub.com

browser-qa

ブラウザ自動化を使用して、デプロイ後のビジュアルテストとUIインタラクション検証を自動化するスキルです。

browser-qa とは?

このスキルは、ブラウザ自動化MCP(Claude-in-Chrome、Playwright、Puppeteer)を活用して、実際のユーザーのようにライブページと対話することで、UIの動作を検証します。主な目的は、ステージング/プレビュー環境への機能デプロイ後やリリース前に、レイアウト、フォーム、インタラクションが正しく動作することを確認することです。スモークテスト、インタラクションテスト、ビジュアルリグレッションテスト、アクセシビリティテストの4つのフェーズに分かれており、デフォルトでは読み取り専用で動作し、本番環境での変更操作(購入、支払い、削除など)を防ぐ安全設計になっています。テスト結果はマークダウン形式のQAレポートとして出力され、各フェーズの成否と詳細な問題が報告されます。対応プラットフォームはClaude-in-Chrome、Playwright、Puppeteerです。

対応✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/affaan-m/everything-claude-code/tree/main/skills/browser-qa

お気に入りのAIに質問する

このエージェントスキルを事前に読み込んだ状態で新しいチャットを開きます。

ドキュメント

Browser QA — ビジュアルテストとインタラクションの自動化

使用タイミング

  • 機能をステージング/プレビューにデプロイした後
  • 複数ページにわたるUIの動作を確認する必要がある場合
  • リリース前に、レイアウト、フォーム、インタラクションが実際に動作することを確認する
  • フロントエンドコードに触れるPRをレビューするとき
  • アクセシビリティ監査とレスポンシブテスト

仕組み

ブラウザ自動化MCP(Claude-in-Chrome、Playwright、Puppeteer)を使用して、実際のユーザーのようにライブページと対話します。

安全第一 — 爆発範囲(デフォルトは読み取り専用)

Browser QAは実際の認証と実際のユーザージャーニーを操作するため、爆発範囲を明示的に扱います。 デフォルトは読み取り専用:本番URLに対して変更を伴うジャーニー(購入、支払い、削除、一括更新)を決して実行してはいけません。明示的なオプトインおよびステージング/プレビューURLが必要です。シードされたテスト認証情報を使用し、実際の本番ログインは絶対に使用しないでください。スクリーンショットを保存する前に、認証情報/トークン/PIIを編集(redact)してください。

フェーズ1:スモークテスト

1. 対象URLに移動
2. コンソールエラーを確認(ノイズをフィルタリング:アナリティクス、サードパーティ)
3. ネットワークリクエストに4xx/5xxがないことを確認
4. デスクトップ + モバイルビューポートでabove-the-foldをスクリーンショット
5. Core Web Vitalsを確認:LCP < 2.5s、CLS < 0.1、INP < 200ms
   (INPは2024年3月にFIDを置き換えました。閾値はweb.devに準拠)

フェーズ2:インタラクションテスト

1. すべてのナビリンクをクリック — デッドリンクがないことを確認
2. 有効なデータでフォームを送信 — 成功状態を確認
3. 無効なデータでフォームを送信 — エラー状態を確認
4. 認証フローをテスト:ログイン→保護ページ→ログアウト(テスト認証情報のみ、本番は絶対に使用しない)
5. 重要なユーザージャーニーをテスト(購入、オンボーディング、検索)
   — デフォルトは読み取り専用。変更を伴うジャーニーは明示的なオプトインがある場合のみステージングで実行(上記「安全第一」を参照)

フェーズ3:ビジュアルリグレッション

1. 主要ページを3つのブレークポイント(375px、768px、1440px)でスクリーンショット
2. コミット済みのベースラインスクリーンショットと比較
   — ベースラインがない場合はINCONCLUSIVEと報告し、決してサイレントPASSにしない
3. 5pxを超えるレイアウトシフト、欠落した要素、はみ出しをフラグ
4. 該当する場合はダークモードをチェック

フェーズ4:アクセシビリティ

1. 各ページでaxe-coreまたは同等のツールを実行
2. WCAG 2.2 AA違反(コントラスト、ラベル、フォーカス順序)をフラグ
3. キーボードナビゲーションがエンドツーエンドで機能することを確認
4. スクリーンリーダーのランドマークをチェック

注意:axe-coreは自動でWCAGの約30〜40%をカバーします。自動テストのパスは必要だが十分ではないため、キーボードナビゲーション、フォーカス順序、スクリーンリーダーのパスは手動チェックが依然として必要です。自動パスのみで「アクセシブル」と報告しないでください。

出力形式

## QAレポート — [URL] — [タイムスタンプ]

### スモークテスト
- コンソールエラー:クリティカル0、警告2(アナリティクスノイズ)
- ネットワーク:すべて200/304、失敗なし
- Core Web Vitals:LCP 1.2s ✓、CLS 0.02 ✓、INP 89ms ✓

### インタラクション
- [✓] ナビリンク:12/12 動作
- [✗] お問い合わせフォーム:無効なメールアドレスに対するエラー状態が欠落
- [✓] 認証フロー:ログイン/ログアウト 動作

### ビジュアル
- [✗] ヒーローセクションが375pxビューポートではみ出している
- [✓] ダークモード:全ページ一貫

### アクセシビリティ
- AA違反2件:ヒーロー画像の代替テキスト欠落、フッターリンクのコントラスト不足

### 判定:修正して出荷(2件の問題、0件のブロッカー)
# 判定 ∈ 出荷 / 修正して出荷 / 出荷不可。ビジュアルベースラインがない場合はINCONCLUSIVEを使用

統合

任意のブラウザMCPで動作:

  • mChild__claude-in-chrome__* ツール(推奨 — 実際のChromeを使用)
  • Playwright経由の mcp__browserbase__*
  • 直接のPuppeteerスクリプト

デプロイ後の監視には /canary-watch と組み合わせて使用してください。

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

accessibility

Design, implement, and audit inclusive digital products using WCAG 2.2 Level AA. Use when building or auditing UI that must meet WCAG 2.2 Level AA, or when reviewing a change for keyboard, contrast, or screen-reader support.

affaan-m/claude-api

Anthropic Claude API patterns for Python and TypeScript. Covers Messages API, streaming, tool use, vision, extended thinking, batches, prompt caching, and Claude Agent SDK. Use when building applications with the Claude API or Anthropic SDKs.

affaan-m/everything-claude-code

End-to-end marketing campaign planning and execution. Covers audience research, positioning, campaign angle definition, landing page copy, email sequences, social posts, ad copy, short-form video scripts, and content calendars. Use as the orchestration layer for multi-channel product launches. Use when planning or executing a multi-channel product launch, or producing landing page, email, social, or ad copy.

affaan-m/everything-claude-code

Development conventions and patterns for everything-claude-code. JavaScript project with conventional commits.

affaan-m/everything-claude-code-conventions

Development conventions and patterns for everything-claude-code. JavaScript project with conventional commits.

affaan-m/frontend-design

Create distinctive, production-grade frontend interfaces with high design quality. Use when the user asks to build web components, pages, or applications and the visual direction matters as much as the code quality.

affaan-m/gget

gget CLI and Python workflow for quick genomic database queries, sequence lookup, BLAST-style searches, enrichment checks, and reproducible bioinformatics evidence logs.

affaan-m/literature-review

Systematic literature-review workflow for academic, biomedical, technical, and scientific topics, including search planning, source screening, synthesis, citation checks, and evidence logging.

affaan-m/motion-ui

Production-ready UI motion system for React/Next.js. Use when implementing animations, transitions, or motion patterns.

affaan-m/project-guidelines-example

Example project-specific skill template based on a real production application.

affaan-m/pubmed-database

Direct PubMed and NCBI E-utilities search workflows for biomedical literature, MeSH queries, PMID lookup, citation retrieval, and API-backed literature monitoring.

affaan-m/scholar-evaluation

Structured scholarly-work evaluation for papers, proposals, literature reviews, methods sections, evidence quality, citation support, and research-writing feedback.

affaan-m/uspto-database

USPTO patent and trademark data workflow for official record lookup, PatentSearch queries, TSDR checks, assignment data, and reproducible IP research logs.

agent-architecture-audit

Full-stack diagnostic for agent and LLM applications. Audits the 12-layer agent stack for wrapper regression, memory pollution, tool discipline failures, hidden repair loops, and rendering corruption. Produces severity-ranked findings with code-first fixes. Essential for developers building agent applications, autonomous loops, or any LLM-powered feature. Use when an agent or LLM feature misbehaves and the failing layer is unknown, or before shipping an agent stack.

agent-eval

Head-to-head comparison of coding agents (Claude Code, Aider, Codex, etc.) on custom tasks with pass rate, cost, time, and consistency metrics. Use when choosing between coding agents, or when a change to an agent setup needs measured pass rate, cost, and time rather than an impression.

agent-harness-construction

Design and optimize AI agent action spaces, tool definitions, and observation formatting for higher completion rates. Use when defining or revising an agent

agentic-engineering

Operate as an agentic engineer using eval-first execution, decomposition, and cost-aware model routing. Use when planning or executing engineering work that agents will carry out end to end.

agentic-os

Build persistent multi-agent operating systems on Claude Code. Covers kernel architecture, specialist agents, slash commands, file-based memory, scheduled automation, and state management without external databases. Use when building a persistent multi-agent system on Claude Code with its own memory, commands, and scheduling.

agent-introspection-debugging

Structured self-debugging workflow for AI agent failures using capture, diagnosis, contained recovery, and introspection reports. Use when an agent run fails and you need a reproducible diagnosis instead of a retry.

agent-payment-x402

Add x402 payment execution to AI agents with per-task budgets, spending controls, and non-custodial wallets. Supports Base through agentwallet-sdk and X Layer through OKX Payments / OKX Agent Payments Protocol. Use when an agent must pay for something itself and needs per-task budgets, spending controls, and a non-custodial wallet.

関連スキル