W Test

blockmatic/basilic-skills/skills/workflow/w-test

作者 blockmatic7e05e2abd052dc6b526e8a28e36d102d42bfd635无许可证1 个星标收录于 2026年10月9日更新于 2026年10月9日仓库6天前更新

Run the repository test scripts and fix failures until they pass.

AI 生成的概览

运行仓库中记录的测试脚本,修复导致失败的根本原因,并反复运行直到测试套件通过。

功能
该技能指导智能体运行 package.json 中记录的测试脚本,选择覆盖本次改动的最小测试套件;当失败原因不明时则使用完整套件。它会记录实际失败的测试,每次只修复一个根本原因,并重新运行失败的命令,直到测试套件全部通过。它明确禁止通过削弱断言或跳过测试来获得通过,并在剩余失败需要人工处理(如密钥、环境问题或不稳定的基础设施)时停止。它还提示在行为或命令发生变化时更新文档。
适用场景
当仓库有记录的测试脚本,且需要诊断并修复失败而不只是报告失败时使用。它适用于希望运行并修复相关测试套件的改动,也包括因失败原因不明而必须运行完整套件的情况。
运行要求
需要一个在 package.json 中记录了测试脚本的仓库,以及可用的测试运行器(如 pnpm 或 Turbo),还需要测试所依赖的环境、密钥或服务。该技能本身不附带脚本,仅为指令。

Run the documented test scripts from package.json (filtered to the change when the repo supports it). Fix owning causes. Do not publish.

  1. Identify the test command for the affected packages (pnpm test, Turbo filters, or the app E2E script). Prefer the narrowest suite that covers the change; use the full suite when the failure is unknown or the user asked for it.
  2. Run the command. Capture failing tests, not a paraphrase.
  3. Fix one owning cause at a time. Re-run the failed command. Do not weaken assertions or skip tests to obtain a pass. Stop when the suite is green or remaining failures need a human (secrets, env, flaky infra).
  4. Docs: /w-docs if behavior or commands changed.

来源与署名

来源:blockmatic/basilic-skills位于skills/workflow/w-test提交7e05e2a

许可证: 无许可证

内容归原作者所有。SourceWeft 从公开仓库中收录这些内容。

举报或申请下架