Skip to content
Development
Skill

/playwright

E2E тестирование UI с Playwright. Запуск, создание тестов, анализ результатов.

From plugin
claude-code-starter
19018 skills5 agents20 commands
Install
$ npx -y skills add alexeykrol/claude-code-starter --skill playwright --agent claude-code

How it fires

How this skill gets triggered: by you, by Claude, or both.

  • Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
  • You can call itInvoke it directly when you want it.
  • Slash command/playwright

Context preview

The summary Claude sees to decide when to auto-load this skill.

E2E тестирование UI с Playwright. Запуск, создание тестов, анализ результатов.

SKILL.md

playwright.SKILL.md
name: playwright
description: "E2E тестирование UI с Playwright. Запуск, создание тестов, анализ результатов."
paths:
  - "src/**/*.tsx"
  - "src/**/*.jsx"
  - "src/**/*.vue"
  - "src/**/*.svelte"
  - "pages/**/*"
  - "app/**/*"
  - "tests/e2e/**/*"
  - "e2e/**/*"
allowed-tools: Read Edit Write Glob Grep Bash
disable-model-invocation: true

Skill: Playwright E2E Testing

Проверка окружения

# Проверить установлен ли Playwright
npx playwright --version 2>/dev/null || echo "Playwright not installed"

Если не установлен:

npm install -D @playwright/test
npx playwright install chromium

Запуск существующих тестов

npx playwright test

С UI отчётом:

npx playwright test --reporter=html

Создание нового теста

При создании E2E теста:

1. Определить сценарий (user flow) 2. Создать файл в `tests/e2e/` или `e2e/` 3. Использовать паттерн:

import { test, expect } from '@playwright/test';

test('описание сценария', async ({ page }) => {
  await page.goto('/');
  // ... actions
  await expect(page.locator('selector')).toBeVisible();
});

Когда использовать

  • После изменений UI-компонентов
  • После изменений роутинга
  • После изменений форм и интерактивных элементов
  • Перед production deploy (обязательно)

Анализ падений

При падении теста: 1. Показать скриншот ошибки (если есть в `test-results/`) 2. Показать trace (если включен) 3. Определить: баг в коде или устаревший тест 4. Предложить фикс

Read more
Ships withclaude-code-starter

Claude Code Starter — это готовая управляющая среда для проектов, в которых основной рабочий агент — Claude Code.

Get the whole plugin