Playwright 测试栈
精选

Playwright 测试栈

一个专注于为 web apps 构建可靠 Playwright workflows 的套件。它涵盖 test patterns、local debugging 以及可靠的 browser interactions。

3 技能 2 安装次数
playwrighttestingbrowser-automatione2e-testingdebugging
4 天前更新

安装

运行此命令,安装该技能包中的全部技能:

npx skillstore add @playwright-test-stack

CLI 会自动检测 Codex 和 Claude Code 文件夹;如果两者都可用,就会同时安装。

概览

使用指南

由 AI 增强

详细指南

## 概述

Playwright 测试栈是一个专注于帮助团队构建可靠 web-app test workflows 的套件。它结合了可靠的 Playwright test patterns、local UI debugging、browser logs、screenshots 和 selector guidance,让你能够带着证据从不稳定的复现推进到稳定的 E2E 或 integration test。

## 快速开始

1. 在你的 OpenClaw workspace 中安装该 plugin:
   `npx skillstore add @playwright-test-stack`
2. 创建或编辑导入 `@playwright/test` 的 `.spec.ts` / `.test.ts` 文件时,使用 `0xbigboss-playwright-best-practices` / `playwright-best-practices` 来组织可靠的 locators、Page Object Models、fixtures、web-first assertions 和 network mocking。
3. 验证本地 web app 时,使用 `7spade-webapp-testing` / `webapp-testing` 来驱动 Playwright checks、捕获 browser screenshots、检查 browser logs,并调试 UI behavior。
4. 当 test 不稳定或 selector-heavy 时,使用 `c0ntr0lledcha0s-playwright-testing` / `playwright-testing` 获取围绕 selectors、locators 和 page objects 的 Playwright-specific E2E 与 integration guidance。

## 关键工作流

- **可靠的 test authoring** — `playwright-best-practices` 帮助优先使用稳定的 locators、Page Object Models、fixtures、web-first assertions 和 network mocking,而不是脆弱的 sleeps 或 CSS chains。
- **本地 web-app verification** — `webapp-testing` 专注于针对本地 app 运行 browser-level checks、收集 screenshots、读取 console output,并诊断 UI failures。
- **Selector 和 page-object debugging** — `playwright-testing` 会在 Playwright config、selectors、locators、page objects,以及 `e2e` 或 `tests` 目录中的 `*.spec.ts` 文件相关场景下启用。

## 提示

- 从 browser evidence 开始:在修改 test 之前,使用 `webapp-testing` 复现问题并收集 logs 或 screenshots。
- 保持修复有纪律性:使用 `playwright-best-practices` 采用 web-first assertions 和稳健的 locator strategy,而不是添加任意 timeouts。
- 重构 page objects 或 integration specs 时使用 `playwright-testing`,以确保 selector changes 与 Playwright conventions 保持一致。

技能

3