[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M72W0T10G3535CSRW1SD916D":3,"skill-same:01M72W0T10G3535CSRW1SD916D":60},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":18,"linkOnly":19,"markdownContent":20,"markdownBody":21,"frontMatter":22,"refName":23,"commitSha":24,"skillDirectory":25,"forksCount":26,"repositoryHtmlUrl":27,"repositoryHomepageUrl":28,"ownerHtmlUrl":29,"ownerBlogUrl":6,"ownerDescription":30,"updatedAt":31,"install":32,"resources":45},"01M72W0T10G3535CSRW1SD916D","tdd",null,"Test-driven development. Use when the user wants to build features or fix bugs test-first, mentions \"red-green-refactor\", or wants integration tests.","rpamis\u002Fcomet","rpamis","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F153429891?v=4","01M72VXBR7EQYMM7KN8C19244V","01M72VXBRYC06QG0ZH0JBGV09V",3298,"MIT","https:\u002F\u002Fgithub.com\u002Frpamis\u002Fcomet\u002Fblob\u002Fmaster\u002Feval\u002Farchives\u002Fgrill-test-20261013\u002Fapplication\u002Fskills\u002Ftdd\u002FSKILL.md",[],[],"2026-11-10 22:39:42",false,"---\r\nname: tdd\r\ndescription: Test-driven development. Use when the user wants to build features or fix bugs test-first, mentions \"red-green-refactor\", or wants integration tests.\r\n---\r\n\r\n# Test-Driven Development\r\n\r\nTDD is the red → green loop. This skill is the reference that makes that loop produce tests worth keeping: what a good test is, where tests go, the anti-patterns, and the rules of the loop. Every section applies on every cycle — consult them before and during the loop, not after.\r\n\r\nWhen exploring the codebase, read `CONTEXT.md` (if it exists) so test names and interface vocabulary match the project's domain language, and respect ADRs in the area you're touching.\r\n\r\n## What a good test is\r\n\r\nTests verify behavior through public interfaces, not implementation details. Code can change entirely; tests shouldn't. A good test reads like a specification — \"user can checkout with valid cart\" tells you exactly what capability exists — and survives refactors because it doesn't care about internal structure.\r\n\r\nSee [tests.md](tests.md) for examples and [mocking.md](mocking.md) for mocking guidelines.\r\n\r\n## Seams — where tests go\r\n\r\nA **seam** is the public boundary you test at: the interface where you observe behavior without reaching inside. Tests live at seams, never against internals.\r\n\r\n**Test only at pre-agreed seams.** Before writing any test, write down the seams under test and confirm them with the user. No test is written at an unconfirmed seam. You can't test everything — agreeing the seams up front is how testing effort lands on the critical paths and complex logic instead of every edge case.\r\n\r\nAsk: \"What's the public interface, and which seams should we test?\"\r\n\r\nWhen the shape of that interface is itself in question — how deep the module is, where the seam belongs, what the interface should expose — use the `\u002Fcodebase-design` skill for the vocabulary. It is the shared source of the module, interface, depth, seam, adapter, leverage and locality terms, and it is a reference to consult, not a session to run.\r\n\r\n## Anti-patterns\r\n\r\n- **Implementation-coupled** — mocks internal collaborators, tests private methods, or verifies through a side channel (querying the database instead of using the interface). The tell: the test breaks when you refactor but behavior hasn't changed.\r\n- **Tautological** — the assertion recomputes the expected value the way the code does (`expect(add(a, b)).toBe(a + b)`, a snapshot derived by hand the same way, a constant asserted equal to itself), so it passes by construction and can never disagree with the code. Expected values must come from an independent source of truth — a known-good literal, a worked example, the spec.\r\n- **Horizontal slicing** — writing all tests first, then all implementation. Bulk tests verify _imagined_ behavior: you test the _shape_ of things rather than user-facing behavior, the tests go insensitive to real changes, and you commit to test structure before understanding the implementation. Work in **vertical slices** instead — one test → one implementation → repeat, each test a **tracer bullet** that responds to what the last cycle taught you.\r\n\r\n## Rules of the loop\r\n\r\n- **Red before green.** Write the failing test first, then only enough code to pass it. Don't anticipate future tests or add speculative features.\r\n- **One slice at a time.** One seam, one test, one minimal implementation per cycle.\r\n- **Refactoring is not part of the loop.** It belongs to the review stage (see the `code-review` skill), not the red → green implementation cycle.\r\n","# Test-Driven Development\r\n\r\nTDD is the red → green loop. This skill is the reference that makes that loop produce tests worth keeping: what a good test is, where tests go, the anti-patterns, and the rules of the loop. Every section applies on every cycle — consult them before and during the loop, not after.\r\n\r\nWhen exploring the codebase, read `CONTEXT.md` (if it exists) so test names and interface vocabulary match the project's domain language, and respect ADRs in the area you're touching.\r\n\r\n## What a good test is\r\n\r\nTests verify behavior through public interfaces, not implementation details. Code can change entirely; tests shouldn't. A good test reads like a specification — \"user can checkout with valid cart\" tells you exactly what capability exists — and survives refactors because it doesn't care about internal structure.\r\n\r\nSee [tests.md](tests.md) for examples and [mocking.md](mocking.md) for mocking guidelines.\r\n\r\n## Seams — where tests go\r\n\r\nA **seam** is the public boundary you test at: the interface where you observe behavior without reaching inside. Tests live at seams, never against internals.\r\n\r\n**Test only at pre-agreed seams.** Before writing any test, write down the seams under test and confirm them with the user. No test is written at an unconfirmed seam. You can't test everything — agreeing the seams up front is how testing effort lands on the critical paths and complex logic instead of every edge case.\r\n\r\nAsk: \"What's the public interface, and which seams should we test?\"\r\n\r\nWhen the shape of that interface is itself in question — how deep the module is, where the seam belongs, what the interface should expose — use the `\u002Fcodebase-design` skill for the vocabulary. It is the shared source of the module, interface, depth, seam, adapter, leverage and locality terms, and it is a reference to consult, not a session to run.\r\n\r\n## Anti-patterns\r\n\r\n- **Implementation-coupled** — mocks internal collaborators, tests private methods, or verifies through a side channel (querying the database instead of using the interface). The tell: the test breaks when you refactor but behavior hasn't changed.\r\n- **Tautological** — the assertion recomputes the expected value the way the code does (`expect(add(a, b)).toBe(a + b)`, a snapshot derived by hand the same way, a constant asserted equal to itself), so it passes by construction and can never disagree with the code. Expected values must come from an independent source of truth — a known-good literal, a worked example, the spec.\r\n- **Horizontal slicing** — writing all tests first, then all implementation. Bulk tests verify _imagined_ behavior: you test the _shape_ of things rather than user-facing behavior, the tests go insensitive to real changes, and you commit to test structure before understanding the implementation. Work in **vertical slices** instead — one test → one implementation → repeat, each test a **tracer bullet** that responds to what the last cycle taught you.\r\n\r\n## Rules of the loop\r\n\r\n- **Red before green.** Write the failing test first, then only enough code to pass it. Don't anticipate future tests or add speculative features.\r\n- **One slice at a time.** One seam, one test, one minimal implementation per cycle.\r\n- **Refactoring is not part of the loop.** It belongs to the review stage (see the `code-review` skill), not the red → green implementation cycle.\r\n",{"name":5,"description":7},"master","a61a2e5b4766e1ad62377dec598e402560a259b6","eval\u002Farchives\u002Fgrill-test-20261013\u002Fapplication\u002Fskills\u002Ftdd",314,"https:\u002F\u002Fgithub.com\u002Frpamis\u002Fcomet","https:\u002F\u002Fdocs.comet.rpamis.com","https:\u002F\u002Fgithub.com\u002Frpamis","More Efficient, Easier to Use, and Less Annoying","2026-11-15 00:26:58",{"source":8,"skillName":5,"commands":33,"prompt":43,"zipAvailable":44},[34,37,40],{"tool":35,"command":36},"npx","npx skills add rpamis\u002Fcomet --skill tdd",{"tool":38,"command":39},"bunx","bunx skills add rpamis\u002Fcomet --skill tdd",{"tool":41,"command":42},"pnpm","pnpm dlx skills add rpamis\u002Fcomet --skill tdd","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Frpamis\u002Fcomet\u002Fblob\u002Fmaster\u002Feval\u002Farchives\u002Fgrill-test-20261013\u002Fapplication\u002Fskills\u002Ftdd\u002FSKILL.md",true,[46,52,56],{"path":47,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":50,"sourceHtmlUrl":51},"agents\u002Fopenai.yaml","REFERENCE","参考文档",90,"https:\u002F\u002Fgithub.com\u002Frpamis\u002Fcomet\u002Fblob\u002Fmaster\u002Feval\u002Farchives\u002Fgrill-test-20261013\u002Fapplication\u002Fskills\u002Ftdd\u002Fagents\u002Fopenai.yaml",{"path":53,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":54,"sourceHtmlUrl":55},"mocking.md",1540,"https:\u002F\u002Fgithub.com\u002Frpamis\u002Fcomet\u002Fblob\u002Fmaster\u002Feval\u002Farchives\u002Fgrill-test-20261013\u002Fapplication\u002Fskills\u002Ftdd\u002Fmocking.md",{"path":57,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":58,"sourceHtmlUrl":59},"tests.md",2291,"https:\u002F\u002Fgithub.com\u002Frpamis\u002Fcomet\u002Fblob\u002Fmaster\u002Feval\u002Farchives\u002Fgrill-test-20261013\u002Fapplication\u002Fskills\u002Ftdd\u002Ftests.md",[61,68,75,82,89,96],{"skillNo":62,"name":63,"nameZh":6,"description":64,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":65,"categories":66,"keywords":67,"publishedAt":18},"01M72W3K6F0C2FKZ8DHABM49R7","writing-skills","Use when creating new skills, editing existing skills, or verifying skills work before deployment","https:\u002F\u002Fgithub.com\u002Frpamis\u002Fcomet\u002Fblob\u002Fmaster\u002Feval\u002Flocal\u002Fskills\u002Fbenchmarks\u002Fdependency\u002Fsuperpowers\u002Fwriting-skills\u002FSKILL.md",[],[],{"skillNo":69,"name":70,"nameZh":6,"description":71,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":72,"categories":73,"keywords":74,"publishedAt":18},"01M72W3HCPQ3GVMACX61QJTD4B","writing-plans","Use when you have a spec or requirements for a multi-step task, before touching code","https:\u002F\u002Fgithub.com\u002Frpamis\u002Fcomet\u002Fblob\u002Fmaster\u002Feval\u002Flocal\u002Fskills\u002Fbenchmarks\u002Fdependency\u002Fsuperpowers\u002Fwriting-plans\u002FSKILL.md",[],[],{"skillNo":76,"name":77,"nameZh":6,"description":78,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":79,"categories":80,"keywords":81,"publishedAt":18},"01M72W3F8EVD3EK4NXJG40P84K","verification-before-completion","Use when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions always","https:\u002F\u002Fgithub.com\u002Frpamis\u002Fcomet\u002Fblob\u002Fmaster\u002Feval\u002Flocal\u002Fskills\u002Fbenchmarks\u002Fdependency\u002Fsuperpowers\u002Fverification-before-completion\u002FSKILL.md",[],[],{"skillNo":83,"name":84,"nameZh":6,"description":85,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":86,"categories":87,"keywords":88,"publishedAt":18},"01M72W3CA9YM0Y6CSXXTNCV1CA","using-git-worktrees","Use when starting feature work that needs isolation from current workspace or before executing implementation plans - ensures an isolated workspace exists via native tools or git worktree fallback","https:\u002F\u002Fgithub.com\u002Frpamis\u002Fcomet\u002Fblob\u002Fmaster\u002Feval\u002Flocal\u002Fskills\u002Fbenchmarks\u002Fdependency\u002Fsuperpowers\u002Fusing-git-worktrees\u002FSKILL.md",[],[],{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":95,"publishedAt":18},"01M72W3AEH0F548GTPRNYRR3H3","test-driven-development","Use when implementing any feature or bugfix, before writing implementation code","https:\u002F\u002Fgithub.com\u002Frpamis\u002Fcomet\u002Fblob\u002Fmaster\u002Feval\u002Flocal\u002Fskills\u002Fbenchmarks\u002Fdependency\u002Fsuperpowers\u002Ftest-driven-development\u002FSKILL.md",[],[],{"skillNo":97,"name":98,"nameZh":6,"description":99,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":100,"categories":101,"keywords":102,"publishedAt":18},"01M72W38EN8NEKX1YN4W9G19Y2","systematic-debugging","Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes","https:\u002F\u002Fgithub.com\u002Frpamis\u002Fcomet\u002Fblob\u002Fmaster\u002Feval\u002Flocal\u002Fskills\u002Fbenchmarks\u002Fdependency\u002Fsuperpowers\u002Fsystematic-debugging\u002FSKILL.md",[],[]]