[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6996CX1VAHWNW5FCPXN4NN3":3,"skill-same:01M6996CX1VAHWNW5FCPXN4NN3":77},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":8,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":16,"licenseFileUrl":17,"sourceHtmlUrl":18,"categories":19,"keywords":30,"publishedAt":31,"linkOnly":32,"markdownContent":33,"markdownBody":34,"frontMatter":35,"refName":36,"commitSha":37,"skillDirectory":38,"forksCount":39,"repositoryHtmlUrl":40,"repositoryHomepageUrl":17,"ownerHtmlUrl":41,"ownerBlogUrl":42,"ownerDescription":43,"updatedAt":44,"install":45,"resources":58},"01M6996CX1VAHWNW5FCPXN4NN3","tdd","测试驱动开发（TDD）","Test-driven development. Use when the user wants to build features or fix bugs test-first, mentions \"red-green-refactor\", or wants integration tests.","测试驱动开发。适用于用户希望以测试优先的方式构建功能或修复缺陷、提到 \"red-green-refactor\"，或希望编写集成测试时。","google\u002Ftf-remote-vars","google","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F1342004?v=4","01M698VYEFDM0VJBZDYYJ2T83S","Google","01M6995SZH9V5ZCYDDJ8XRTJXB",1,"Apache-2.0",null,"https:\u002F\u002Fgithub.com\u002Fgoogle\u002Ftf-remote-vars\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fmattpocock\u002Fengineering\u002Ftdd\u002FSKILL.md",[20,25],{"categoryNo":21,"categoryName":22,"taxonomyType":23,"taxonomyTypeDesc":24},"01M8BQ6TQZN6R52WBJ9H8NRMQM","软件开发工程师","PROFESSION","适用职业",{"categoryNo":26,"categoryName":27,"taxonomyType":28,"taxonomyTypeDesc":29},"01M8BQJH394GT47X57A9Q8G7HX","测试与质量保障","SCENARIO","使用场景",[5],"2026-11-10 10:12:30",false,"---\nname: tdd\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.\n---\n\n# Test-Driven Development\n\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.\n\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.\n\n## What a good test is\n\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.\n\nSee [tests.md](tests.md) for examples and [mocking.md](mocking.md) for mocking guidelines.\n\n## Seams — where tests go\n\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.\n\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.\n\nAsk: \"What's the public interface, and which seams should we test?\"\n\n## Anti-patterns\n\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.\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.\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.\n\n## Rules of the loop\n\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.\n- **One slice at a time.** One seam, one test, one minimal implementation per cycle.\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.\n","# Test-Driven Development\n\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.\n\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.\n\n## What a good test is\n\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.\n\nSee [tests.md](tests.md) for examples and [mocking.md](mocking.md) for mocking guidelines.\n\n## Seams — where tests go\n\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.\n\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.\n\nAsk: \"What's the public interface, and which seams should we test?\"\n\n## Anti-patterns\n\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.\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.\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.\n\n## Rules of the loop\n\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.\n- **One slice at a time.** One seam, one test, one minimal implementation per cycle.\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.\n",{"name":5,"description":7},"main","ad283c1ebaa3cc8c77bd59e5d665e3532658a253",".github\u002Fskills\u002Fmattpocock\u002Fengineering\u002Ftdd",0,"https:\u002F\u002Fgithub.com\u002Fgoogle\u002Ftf-remote-vars","https:\u002F\u002Fgithub.com\u002Fgoogle","https:\u002F\u002Fopensource.google\u002F","Google ❤️ Open Source","2026-09-02 16:15:11",{"source":9,"skillName":5,"commands":46,"prompt":56,"zipAvailable":57},[47,50,53],{"tool":48,"command":49},"npx","npx skills add google\u002Ftf-remote-vars --skill tdd",{"tool":51,"command":52},"bunx","bunx skills add google\u002Ftf-remote-vars --skill tdd",{"tool":54,"command":55},"pnpm","pnpm dlx skills add google\u002Ftf-remote-vars --skill tdd","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fgoogle\u002Ftf-remote-vars\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fmattpocock\u002Fengineering\u002Ftdd\u002FSKILL.md",true,[59,65,69,73],{"path":60,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":63,"sourceHtmlUrl":64},"agents\u002Fopenai.yaml","REFERENCE","参考文档",87,"https:\u002F\u002Fgithub.com\u002Fgoogle\u002Ftf-remote-vars\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fmattpocock\u002Fengineering\u002Ftdd\u002Fagents\u002Fopenai.yaml",{"path":66,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":67,"sourceHtmlUrl":68},"mocking.md",1481,"https:\u002F\u002Fgithub.com\u002Fgoogle\u002Ftf-remote-vars\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fmattpocock\u002Fengineering\u002Ftdd\u002Fmocking.md",{"path":70,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":71,"sourceHtmlUrl":72},"refactoring.md",387,"https:\u002F\u002Fgithub.com\u002Fgoogle\u002Ftf-remote-vars\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fmattpocock\u002Fengineering\u002Ftdd\u002Frefactoring.md",{"path":74,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":75,"sourceHtmlUrl":76},"tests.md",2214,"https:\u002F\u002Fgithub.com\u002Fgoogle\u002Ftf-remote-vars\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fmattpocock\u002Fengineering\u002Ftdd\u002Ftests.md",[78,93,109,123,135,147],{"skillNo":79,"name":80,"nameZh":81,"description":82,"descriptionZh":83,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":84,"licenseFileUrl":17,"sourceHtmlUrl":85,"categories":86,"keywords":91,"publishedAt":31},"01M69974QH2M2EJPN5VDPS6SP4","ponytail","极简编码方案","Forces the laziest solution that actually works, simplest, shortest, most minimal. Channels a senior dev who has seen everything: question whether the task needs to exist at all (YAGNI), reach for the standard library before custom code, native platform features before dependencies, one line before fifty. Supports intensity levels: lite, full (default), ultra. Use on ANY coding task: writing, adding, refactoring, fixing, reviewing, or designing code, and choosing libraries or dependencies. Also use whenever the user says \"ponytail\", \"be lazy\", \"lazy mode\", \"simplest solution\", \"minimal solution\", \"yagni\", \"do less\", or \"shortest path\", or complains about over-engineering, bloat, boilerplate, or unnecessary dependencies. Do NOT use for non-coding requests (general knowledge, prose, translation, summaries, recipes).","强制采用最懒但实际可行、最简单、最短、最精简的解决方案。化身一位见多识广的高级开发者：质疑任务本身是否有存在的必要（YAGNI），在编写自定义代码之前先用标准库，在引入依赖之前先用原生平台能力，一行胜过五十行。支持强度级别：lite、full（默认）、ultra。适用于任何编码任务：编写、添加、重构、修复、审查或设计代码，以及选择库或依赖。当用户说「ponytail」「be lazy」「lazy mode」「simplest solution」「minimal solution」「yagni」「do less」或「shortest path」，或抱怨过度工程、臃肿、样板代码或不必要的依赖时也使用。不用于非编码请求（常识、散文、翻译、摘要、食谱）。","MIT","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Ftf-remote-vars\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fponytail\u002Fponytail\u002FSKILL.md",[87,88],{"categoryNo":21,"categoryName":22,"taxonomyType":23,"taxonomyTypeDesc":24},{"categoryNo":89,"categoryName":90,"taxonomyType":28,"taxonomyTypeDesc":29},"01M8BT7QVANT4709358VEJK53E","代码实现",[80,92],"writing",{"skillNo":94,"name":95,"nameZh":96,"description":97,"descriptionZh":98,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":16,"licenseFileUrl":17,"sourceHtmlUrl":99,"categories":100,"keywords":105,"publishedAt":31},"01M69973EVAC0CR9JWAJH172SA","ponytail-review","代码过度工程审查","Code review focused exclusively on over-engineering. Finds what to delete: reinvented standard library, unneeded dependencies, speculative abstractions, dead flexibility. One line per finding: location, what to cut, what replaces it. Use when the user says \"review for over-engineering\", \"what can we delete\", \"is this over-engineered\", \"simplify review\", or invokes \u002Fponytail-review. Complements correctness-focused review, this one only hunts complexity.","专注于过度工程化的代码审查。找出应当删除的内容：重复造标准库轮子、不必要的依赖、投机性的抽象、僵死的灵活性。每条发现一行：位置、要删什么、用什么替代。当用户说「review for over-engineering」「what can we delete」「is this over-engineered」「simplify review」或调用 \u002Fponytail-review 时使用。与侧重正确性的代码审查互补，本技能只搜寻复杂性。","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Ftf-remote-vars\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fponytail\u002Fponytail-review\u002FSKILL.md",[101,102],{"categoryNo":21,"categoryName":22,"taxonomyType":23,"taxonomyTypeDesc":24},{"categoryNo":103,"categoryName":104,"taxonomyType":28,"taxonomyTypeDesc":29},"01M8BT7QTSZKB08EAW9P9ZCDNQ","设计评审与架构优化",[106,107,108],"review","ponytail review","code review",{"skillNo":110,"name":111,"nameZh":112,"description":113,"descriptionZh":114,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":16,"licenseFileUrl":17,"sourceHtmlUrl":115,"categories":116,"keywords":121,"publishedAt":31},"01M699719B6E12N38RB2R5CB6K","ponytail-help","ponytail 命令速查","Quick-reference card for all ponytail modes, skills, and commands. One-shot display, not a persistent mode. Trigger: \u002Fponytail-help, \"ponytail help\", \"what ponytail commands\", \"how do I use ponytail\".","面向所有 ponytail 模式、技能和命令的快速参考卡。一次性展示，不是持久模式。触发词：\u002Fponytail-help、“ponytail help”“有哪些 ponytail 命令”“如何使用 ponytail”。","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Ftf-remote-vars\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fponytail\u002Fponytail-help\u002FSKILL.md",[117,118],{"categoryNo":21,"categoryName":22,"taxonomyType":23,"taxonomyTypeDesc":24},{"categoryNo":119,"categoryName":120,"taxonomyType":28,"taxonomyTypeDesc":29},"01M8BSTR9G4A4GZ0VB2DFN9490","开发环境与工具链管理",[122],"ponytail help",{"skillNo":124,"name":125,"nameZh":126,"description":127,"descriptionZh":128,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":16,"licenseFileUrl":17,"sourceHtmlUrl":129,"categories":130,"keywords":133,"publishedAt":31},"01M699707ZF916CP1KFVVAGVS7","ponytail-gain","代码优化成效看板","Show ponytail's measured impact as a compact scoreboard: less code, less cost, more speed, from the benchmark medians. One-shot display, not a persistent mode, and not a per-repo number. Trigger: \u002Fponytail-gain, \"ponytail gain\", \"what does ponytail save\", \"show ponytail impact\", \"ponytail scoreboard\".","以精简的记分板展示 ponytail 的可量化成效：基于基准测试中位数，代码更少、成本更低、速度更快。一次性展示，不是持久模式，也不是针对单个仓库的数值。触发词：\u002Fponytail-gain、“ponytail gain”“ponytail 节省了多少”“展示 ponytail 成效”“ponytail 记分板”。","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Ftf-remote-vars\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fponytail\u002Fponytail-gain\u002FSKILL.md",[131,132],{"categoryNo":21,"categoryName":22,"taxonomyType":23,"taxonomyTypeDesc":24},{"categoryNo":103,"categoryName":104,"taxonomyType":28,"taxonomyTypeDesc":29},[134],"ponytail gain",{"skillNo":136,"name":137,"nameZh":138,"description":139,"descriptionZh":140,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":16,"licenseFileUrl":17,"sourceHtmlUrl":141,"categories":142,"keywords":145,"publishedAt":31},"01M6996Z5E4BFG6ZF2D2AB8NG7","ponytail-debt","技术债务台账整理","Harvest every `ponytail:` comment in the codebase into a debt ledger, so the deliberate shortcuts and deferrals ponytail leaves behind get tracked instead of rotting into \"later means never\". Use when the user says \"ponytail debt\", \"\u002Fponytail-debt\", \"what did ponytail defer\", \"list the shortcuts\", \"ponytail ledger\", or \"what did we mark to do later\". One-shot report, changes nothing.","将代码库中的每个 `ponytail:` 注释汇总到一份债务台账中，使 ponytail 有意留下的捷径和延后事项得到跟踪，而不是烂尾成“以后再说就等于永远不做”。当用户说“ponytail 债务”“\u002Fponytail-debt”“ponytail 推迟了什么”“列出这些捷径”“ponytail 台账”或“我们标记了哪些以后要做的事”时使用。一次性报告，不做任何更改。","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Ftf-remote-vars\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fponytail\u002Fponytail-debt\u002FSKILL.md",[143,144],{"categoryNo":21,"categoryName":22,"taxonomyType":23,"taxonomyTypeDesc":24},{"categoryNo":103,"categoryName":104,"taxonomyType":28,"taxonomyTypeDesc":29},[146],"ponytail debt",{"skillNo":148,"name":149,"nameZh":150,"description":151,"descriptionZh":152,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":16,"licenseFileUrl":17,"sourceHtmlUrl":153,"categories":154,"keywords":157,"publishedAt":31},"01M6996XMDTAYY2WSGMKTPGPGR","ponytail-audit","代码库过度工程审计","Whole-repo audit for over-engineering. Like ponytail-review, but scans the entire codebase instead of a diff: a ranked list of what to delete, simplify, or replace with stdlib\u002Fnative equivalents. Use when the user says \"audit this codebase\", \"audit for over-engineering\", \"what can I delete from this repo\", \"find bloat\", \"ponytail-audit\", or \"\u002Fponytail-audit\". One-shot report, does not apply fixes.","对整个代码仓库进行过度工程审计。类似 ponytail-review，但扫描的是整个代码库而非代码差异：给出一份按优先级排序的清单，列出可删除、简化或替换为标准库\u002F原生等效实现的内容。当用户说“审计这个代码库”“检查过度工程”“这个仓库里能删掉什么”“找出冗余”“ponytail-audit”或“\u002Fponytail-audit”时使用。一次性报告，不会应用任何修复。","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Ftf-remote-vars\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fponytail\u002Fponytail-audit\u002FSKILL.md",[155,156],{"categoryNo":21,"categoryName":22,"taxonomyType":23,"taxonomyTypeDesc":24},{"categoryNo":103,"categoryName":104,"taxonomyType":28,"taxonomyTypeDesc":29},[158,106],"ponytail audit"]