AgentSkillsCN

pest-testing

使用适合项目的框架编写并维护测试套件。适用于新增或修复单元测试、功能测试、集成测试、E2E测试,以及发布门禁的场景。

SKILL.md
--- frontmatter
name: pest-testing
description: >-
  Writes and maintains test suites with a project-appropriate framework.
  Use when adding or fixing unit/feature/integration/e2e tests and release gates.

Testing Skill

When to Apply

  • User asks to add or fix tests.
  • Changes require validation coverage.

Workflow

  1. Read test strategy from specs/qa-spec.md and specs/specs.md.
  2. Detect test framework from repo (Pest, PHPUnit, Jest, Vitest, Playwright, etc.).
  3. Add minimal high-value tests:
    • happy path
    • validation/edge path
    • auth/permission path when applicable
  4. Run the smallest relevant test subset first, then broader suite if needed.

Quality Bar

  • Tests are deterministic.
  • Assertions verify behavior, not implementation detail.
  • New tests fail without the fix and pass with it.