skills/test-case-generator/SKILL.md
Use when 需要根据需求文档、接口说明、原型或已有用例生成测试场景和结构化测试用例,尤其适用于“生成测试用例”“需求转测试用例”“测试场景梳理”“补齐测试覆盖”等请求。
npx skillsauth add changye01/tech-design-doc test-case-generatorInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
references/test-design-rules.md,按规则扩展正常、边界、异常、权限、日志、数据一致性、持久化和综合场景。assets/scene-template.md 先在对话中输出 Markdown 场景地图草稿,明确“测什么”,并单独整理 本次确认规则 小节,用于记录用户补充的明确规则。references/coverage-checklist.md,补充缺失维度,标记信息不足待确认项和超范围项,并检查 本次确认规则 是否已回填到场景地图。assets/test-case-template.md 输出结构化测试用例 Markdown。第二阶段最终输出模板固定为 5 列:编号 / 测试功能点 / 前置条件 / 测试步骤 / 预期结果;Markdown 默认按场景地图中的“场景分组”分段,每个场景组下使用 5 列表格,不改写为段落叙述。结构化测试用例.md 保存到目标位置;保存时必须覆盖旧版本,不得把旧草稿追加到确认版文件中,也不得在保存前直接提示下游 test-data-generator。scripts/validate_cases.py 检查结构化测试用例 Markdown 是否包含关键字段和综合场景。覆盖全面先场景,后用例本次确认规则 小节测试场景地图.md结构化测试用例.md结构化测试用例.md,保存前不得提示下游 skilltest-data-generator1 个值至少 1 条用例 展开;仅在用户明确要求压缩时才允许合并Markdown (.md) 作为输入;txt 次之,docx 和 pdf 可用但建议先转成纯文本或 Markdown。Cloud Document Converter 转成 .md。.docx 文件,也建议先转成 .md,再交给本 Skill 处理。测试场景地图.md 后,再展开结构化测试用例;是否还有命名、输出位置或格式约束?必须包含:
第一阶段输出要求:
本次确认规则<需求名称>_测试场景地图.md必须包含:
<需求名称>_结构化测试用例.md结构化测试用例.mdtest-data-generator模块、场景组、关联需求点、优先级 等信息默认保留在第一阶段场景地图中,不再作为第二阶段默认列references/test-design-rules.mdreferences/coverage-checklist.mdreferences/quality-rubric.mdassets/scene-template.mdassets/test-case-template.mdassets/test-case-example.md生成结构化测试用例后,运行:
python scripts/validate_cases.py <测试用例文件路径>
完成结构校验后,再参考 references/quality-rubric.md 做一轮内容质量自查,重点检查可追溯、可执行、可验证、不混测、不重复和关键覆盖是否到位。
如果提示缺少关键字段或缺少综合场景,必须先回改已保存的 Markdown 再重新校验;如果结构无问题但仍存在漏测、弱预期、混测或重复问题,则按质量评审标准继续修正。
完成验证并确认这版结构化测试用例可作为后续输入后,若用户下一步目标是“根据已确认测试用例准备执行数据”,建议继续提供:
结构化测试用例.mdreference-pack 路径(通常位于 reference-packs/...,包含 tables/*.sql + table_samples/*.csv)其中技术方案是 test-data-generator 的核心输入之一;如果涉及派生字段、状态映射、历史修复、权限规则或日志映射,应该优先补齐技术方案,再切换到 test-data-generator。随后由其在保留 结构化测试用例.md 作为基线稿的前提下,继续输出 测试执行清单.md。
testing
Create, edit, improve, or audit AgentSkills. Use when creating a new skill from scratch or when asked to improve, review, audit, tidy up, or clean up an existing skill or SKILL.md file. Also use when editing or restructuring a skill directory (moving files to references/ or scripts/, removing stale content, validating against the AgentSkills spec). Triggers on phrases like "create a skill", "author a skill", "tidy up a skill", "improve this skill", "review the skill", "clean up the skill", "audit the skill".
testing
Host security hardening and risk-tolerance configuration for OpenClaw deployments. Use when a user asks for security audits, firewall/SSH/update hardening, risk posture, exposure review, OpenClaw cron scheduling for periodic checks, or version status checks on a machine running OpenClaw (laptop, workstation, Pi, VPS).
testing
Create, edit, improve, or audit AgentSkills. Use when creating a new skill from scratch or when asked to improve, review, audit, tidy up, or clean up an existing skill or SKILL.md file. Also use when editing or restructuring a skill directory (moving files to references/ or scripts/, removing stale content, validating against the AgentSkills spec). Triggers on phrases like "create a skill", "author a skill", "tidy up a skill", "improve this skill", "review the skill", "clean up the skill", "audit the skill".
testing
Host security hardening and risk-tolerance configuration for OpenClaw deployments. Use when a user asks for security audits, firewall/SSH/update hardening, risk posture, exposure review, OpenClaw cron scheduling for periodic checks, or version status checks on a machine running OpenClaw (laptop, workstation, Pi, VPS).