test-dev
Use when writing xUnit unit tests, integration tests with real databases, E2E Playwright tests, or Rust (cargo test/nextest) and Go (go test) tests. Do not use for application or persistence implementation.
- License 许可
- MIT
- 最近更新
- 2026-11-15
- Stars
- ★ 23
- Forks
- 3
01 前言 Front Matter
- name
- test-dev
- license
- MIT
- description
- Use when writing xUnit unit tests, integration tests with real databases, E2E Playwright tests, or Rust (cargo test/nextest) and Go (go test) tests. Do not use for application or persistence implementation.
02 资源文件 6
- 参考文档references/e2e-test-patterns.md7.4 KB
- 参考文档references/integration-test-patterns.md3.7 KB
- 参考文档references/mock-usage-analysis.md4.4 KB
- 参考文档references/rust-go-test-patterns.md4.3 KB
- 参考文档references/test-maintainability.md4.6 KB
- 参考文档references/unit-test-patterns.md3.5 KB
03 SKILL.md 正文
Test Developer
Test policy lives in the path declared as <test-coding-standard> in the repository
root AGENTS.md. Language-level C# decisions live in the path declared as
<csharp-coding-standard>. Fetch those with docs_get_coding_standard_for_technology
before the references below, naming each technology and the topic you need; read a file only
when the tool is missing — this skill is procedure, not policy.
Identify your sub-task and read ONLY the relevant reference before proceeding.
| Sub-Task | When to Use | Reference |
|---|---|---|
| Unit Test Patterns | xUnit, NSubstitute, FluentAssertions, pure domain/service/validator logic tests | Unit Test Patterns |
| Integration Test Patterns | Real SQL Server, LocalDB/Docker, WebApplicationFactory, repository and API tests | Integration Test Patterns |
| E2E / Browser Tests | Playwright MCP tools, user flows, form submissions, multi-step scenarios | E2E Test Patterns |
| Rust and Go Test Patterns | #[cfg(test)] modules, tests/ integration crates, cargo nextest, table-driven _test.go tests, t.Run subtests, -race, fakes behind traits and interfaces |
Rust and Go Test Patterns |
| Mock Usage Analysis | Classify mocks as dead/unreachable/redundant/used; detect over-mocking | Mock Usage Analysis |
| Test Maintainability | Magic values, duplicate setup, assertion overload, brittle naming — detect and refactor | Test Maintainability |
Rule: Read only the reference(s) relevant to your current task. Do not pre-load all references.
Execution & Parallelization Invariants
- Adversarial RED/GREEN role boundary: Maintain strict adversarial separation between RED phase test authoring (
test-dev) and GREEN phase implementation (csharp-dev, etc.). Never collapse RED and GREEN into a single worker dispatch: test authors author tests and verify failures; implementers make them pass, while preserving independent verification at task completion. - Same-role task bundling: Tasks belonging to the same specialist role are bundled in same-role micro-task dispatches to minimize context thrash.
- Build once, test many with direct assembly runner: Do not rebuild or recompile the entire solution on every iteration. The direct assembly runner is the language-specific form for a .NET solution — its exact assembly path and target framework come from the host's test standard, in its
## Completionsection — while other stacks use their own runners (such ascargo testorgo test). Use--no-buildfor targeted test runs, or execute the pre-built test assembly directly:dotnet <path-to-test-assembly>.dll -class "<Namespace>.<TestClass>" - Zero-stash RED proof rule: Forbid
git stashfor RED proofs; never rungit stashto fake clean working state. Run the RED proof against a clean base checkout, throwaway copy, or isolated worktree before any implementation edits exist. - Per-task artifact isolation: Isolate intermediate build and review artifacts using unique per-task paths, passing
dotnet build --artifacts-path .agent_scratchpad/<task-id>/artifactsfor build output isolation, andkyber-weave review gates . --agent <agent> --out artifacts/task-gate-<task-id>.json(or.agent_scratchpad/<task-id>/task-gate.json) so concurrent task-gate runs never overwrite one another.
Completion Digest
The Discovery: codegraph N, docs N, direct reads N header precedes the 6-field completion digest schema:
STATUS: PASS | FAIL | ESCALATION
FILES: <comma-separated-paths>
TESTS: total=N failed=N passed=N
COMMIT: <commit-sha | NONE>
REMOTE_HEAD: <remote-head-sha | UNPUSHED>
TASK_GATE: PASS | FAIL | NONE_DECLARED | NONE_APPLICABLE | UNAVAILABLE — agent=test-dev gates=<n> failed=<ids|none> skipped=<n> report=<path> runs=<k>
04 同仓库更多 Skills
pr-review
Use to run the pre-merge pull request review checklist so required validations are never skipped. Use when reviewing or approving a pull request before merge. Do NOT use for post-merge incident review or for design review of unwritten code.
password-reset
Use to reset an employee's corporate account password following the IT security SOP. Use when a user reports they are locked out, forgot their password, or needs a password reset. Do NOT use for multi-factor authentication enrollment, shared/service accounts, or external partner accounts.
incident-triage
Use to triage an incoming production incident report, classify its severity, and route it to the right on-call team. Use when someone reports an outage, degradation, or production error. Do NOT use for routine service requests, feature questions, or non-production environments.
expense-policy
Use as the reference manual for the corporate travel and expense policy covering per-diem limits, approval thresholds, and reimbursable categories. Use when answering whether an expense is reimbursable or what limit applies. Do NOT use to submit, approve, or modify expense reports.
Vague_Helper
Helps with HR questions.
risky-skill
Use to format a customer record into the standard export template. Use when exporting a single customer record. Do NOT use for bulk exports.