qa-generated-test-case
Skill0 starsChanged 2 months agoMITView on GitHub
Generate high-coverage Chinese functional and business-flow test cases from PRDs, especially Web admin or platform PRDs. Use when Codex is asked to extract PRD text, design QA coverage, generate the fixed 7-column testcase table, export CSV/XLSX, validate testcase format, or optionally consult an external indexed PRD memory source without reading full historical archives.
In this repository42 other files it gives its agents.
- ai-pr-redteamSkill
- ai-servicesSkill
- build-work-memorySkill
- ceo-calendar-inviteSkill
- ceo-document-reviewSkill
- ceo-email-classifierSkill
- ceo-feedback-iterationSkill
- ceo-feedback-processingSkill
- ceo-mail-reviewSkill
- ceo-meeting-workSkill
- ceo-message-triageSkill
- ceo-minutes-syncSkill
- ceo-personnel-communicationSkill
- ceo-wechatSkill
- ceo-work-trackingSkill
- codex-model-capacity-retrySkill
- daily-frontier-tech-discoverySkill
- dengbao-code-auditSkill
- dingtalk-browser-exportSkill
- dingtalk-knowledge-organizeSkill
- dingtalk-minutes-access-requestSkill
- dingtalk-oa-approvalSkill
- dingtang-okr-reviewSkill
- fundflow-investor-meetingSkill
- fxiaoke-crm-cliSkill
- internal-app-standardsSkill
- ocrSkill
- pm-data-adaptation-assistantSkill
- project-delivery-document-collectionSkill
- senior-technical-product-evaluationSkill
- spec-intakeSkill
- sso-oidc-onboardingSkill
- stardust-interviewSkill
- production-devops-sreSkill
- stardust-ttsSkill
- startask-io-contract-auditSkill
- task-managementSkill
- transcribeSkill
- veyra-timesheetSkill
- vibe-coding-rescueSkill
- vibe-codingSkill
- video-transcribeSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
13 rules. About 0 are common, 3 are distinctive, and 10 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
10
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 33
Not allowed in the skill:
- Very specific: line 39
If historical context is needed, use an explicitly provided private data directory, memory/document store, or separate data package.
- Very specific: line 46
Use scripts/extract_prd.py <prd.docx> --out <run_dir>/00-extracted-prd.txt for Word files.
- Very specific: line 48
If the user provides an external index or private PRD archive, use scripts/prd_memory_retrieval.py search-memory with deterministic filters …
- Very specific: line 50
Use a non-repo run directory such as /tmp/qa-testcase-run/<topic> or a user-approved project output directory.
- Very specific: line 51
Follow the workflow prompt structure.
- Very specific: line 56
Use scripts/testcase_table_tools.py to parse, validate, create CSV, and create XLSX.
- Very specific: line 73
Do not include literal \n, <br>, or <br/> inside case text.
- Very specific: line 74
Keep case names unique and concrete.
- Very specific: line 75
Put uncertain or missing PRD information under 待确认问题, not into formal cases.
- Distinctive: line 125
If a script reports a format error, fix the source Markdown/CSV and rerun validation before reporting completion.
- Distinctive: line 157
Before final response, verify:
- Very specific: line 166
Use references/quality-scorecard.md when the user asks for scoring, benchmarking, or improvement over manual writing efficiency.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
QA Generated Test Case
Core Rule
Act as a senior QA analyst for Web 管理后台 and platform product requirements. Generate executable functional and business-flow test cases from the current PRD, not generic checklists.
Always prioritize:
- 功能点覆盖
- 主流程、分支流程、状态流转
- 异常场景
- 边界值和多条件组合
- 角色权限
- 上下游依赖和历史兼容风险
The current PRD is the primary source. If external retrieval results conflict with the current PRD, use the current PRD and list the conflict under 待确认问题.
Data Boundary
This skill package must stay reusable and lightweight.
Allowed in the skill:
- Workflow prompts, output rules, quality checks, and PR description templates.
- Reusable scripts for PRD extraction, testcase table validation/export, and external-memory retrieval.
- Small tests and synthetic fixtures.
Not allowed in the skill:
- One-off run outputs such as
runs/, generated CSV/XLSX files, extracted PRD text, or temporary design drafts. - Customer/project/private historical PRDs, full PRD digests, large source indexes, or business-memory archives.
- Tokens, local config, browser state, or any sensitive source material.
If historical context is needed, use an explicitly provided private data directory, memory/document store, or separate data package. At runtime, read only the retrieval result produced by scripts/prd_memory_retrieval.py search-memory; do not read the full historical archive.
See references/data-boundary.md and references/retrieval-design.md.
Quick Workflow
- Extract PRD text.
Use
scripts/extract_prd.py <prd.docx> --out <run_dir>/00-extracted-prd.txtfor Word files. Markdown and text files can be read directly or passed through the same script. - Optionally retrieve historical context.
If the user provides an external index or private PRD archive, use
scripts/prd_memory_retrieval.py search-memorywith deterministic filters first, then keyword similarity, and read only the top N retrieval output. - Produce process artifacts outside the skill package.
Use a non-repo run directory such as
/tmp/qa-testcase-run/<topic>or a user-approved project output directory. - Follow the workflow prompt structure.
See
references/workflow.md. - Enforce the fixed final output format.
See
references/output-format.md. The official final table has exactly 7 columns. - Validate and export.
Use
scripts/testcase_table_tools.pyto parse, validate, create CSV, and create XLSX. - Persist reusable learning only with user approval. For durable project memory, write to the configured memory/document store or a private data package. Do not sync historical material back into this skill.
Final Output Contract
The final testcase table must have this exact header and order:
用例名称 | 所属模块 | 前置条件 | 步骤描述 | 预期结果 | 用例等级 | 编辑模式
Hard constraints:
所属模块is fixed for all rows as/<需求名称>.编辑模式is alwaysSTEP.用例等级isP0,P1,P2, orP3.步骤描述uses numbered steps like[1]...;[2]....预期结果uses the same step numbers as步骤描述; do not add more expected-result step numbers than action step numbers.- Do not include literal
\n,<br>, or<br/>inside case text. - Keep case names unique and concrete. Avoid vague names like
创建成功. - Put uncertain or missing PRD information under
待确认问题, not into formal cases.
Script Usage
Extract a Word PRD:
python3 scripts/extract_prd.py "/path/to/需求.docx" --out "/tmp/qa-testcase-run/topic/00-extracted-prd.txt"Build an external historical-memory index from a private data directory:
python3 scripts/prd_memory_retrieval.py build-index \
--source-dir "/path/to/private-prd-memory" \
--out-index "/path/to/private-prd-memory/index.jsonl" \
--out-csv "/path/to/private-prd-memory/index.csv"Retrieve top N snippets before testcase generation:
python3 scripts/prd_memory_retrieval.py search-memory \
--index "/path/to/private-prd-memory/index.jsonl" \
--product-line "Rosetta" \
--module "任务列表" \
--tags "筛选,导出" \
--query "跨页选中 导出筛选结果" \
--top-n 5 \
--out "/tmp/qa-testcase-run/topic/retrieved-memory.md"Parse Markdown table, validate, and generate CSV/XLSX:
python3 scripts/testcase_table_tools.py from-markdown \
--markdown "/tmp/qa-testcase-run/topic/03-testcases.md" \
--csv "/tmp/qa-testcase-run/topic/04-testcases-excel.csv" \
--xlsx "/tmp/qa-testcase-run/topic/05-testcases.xlsx" \
--module "/需求名称"Validate an existing CSV:
python3 scripts/testcase_table_tools.py validate-csv \
--csv "/tmp/qa-testcase-run/topic/04-testcases-excel.csv" \
--module "/需求名称"If a script reports a format error, fix the source Markdown/CSV and rerun validation before reporting completion.
Process Artifact Expectations
01-normalized-prd.md should include:
- 背景与目标
- 角色与对象
- 功能范围
- 业务规则和字段映射
- 测试假设与待确认
02-test-design.md should include:
- 测试目标
- 覆盖分层
- 关键业务规则转测试规则
- 高风险点
- 测试数据建议
- 待确认问题
- 覆盖说明
03-testcases.md should include:
- Final 7-column Markdown testcase table
- 待确认问题
- 覆盖说明
04-testcases-excel.csv and 05-testcases.xlsx must be generated from the same final table and kept outside this repository unless the user explicitly asks to inspect a sample.
Quality Gate
Before final response, verify:
- The PRD was actually read or extracted.
- External retrieval was used only when an approved index/data source was provided; only top N snippets were read.
- Main flow, branches, exceptions, boundaries, permissions, and dependencies are represented.
- Final table validates with
errors=none. - XLSX opens structurally, or at least passes zip integrity validation.
- Any durable memory write or document upload was explicitly approved and stored outside the skill package.
Use references/quality-scorecard.md when the user asks for scoring, benchmarking, or improvement over manual writing efficiency.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

