universal-dev-standards 3.5.1-beta.1 → 3.5.1-beta.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/uds.js +2 -0
- package/bundled/core/ai-instruction-standards.md +205 -0
- package/bundled/core/anti-hallucination.md +684 -0
- package/bundled/core/changelog-standards.md +556 -0
- package/bundled/core/checkin-standards.md +935 -0
- package/bundled/core/code-review-checklist.md +684 -0
- package/bundled/core/commit-message-guide.md +915 -0
- package/bundled/core/documentation-structure.md +1117 -0
- package/bundled/core/documentation-writing-standards.md +487 -0
- package/bundled/core/error-code-standards.md +382 -0
- package/bundled/core/git-workflow.md +859 -0
- package/bundled/core/logging-standards.md +323 -0
- package/bundled/core/project-structure.md +354 -0
- package/bundled/core/refactoring-standards.md +636 -0
- package/bundled/core/spec-driven-development.md +207 -0
- package/bundled/core/test-completeness-dimensions.md +536 -0
- package/bundled/core/test-driven-development.md +995 -0
- package/bundled/core/testing-standards.md +3061 -0
- package/bundled/core/versioning.md +902 -0
- package/bundled/locales/README.md +88 -0
- package/bundled/locales/zh-CN/CHANGELOG.md +705 -0
- package/bundled/locales/zh-CN/CLAUDE.md +213 -0
- package/bundled/locales/zh-CN/MAINTENANCE.md +689 -0
- package/bundled/locales/zh-CN/README.md +707 -0
- package/bundled/locales/zh-CN/STANDARDS-MAPPING.md +177 -0
- package/bundled/locales/zh-CN/adoption/ADOPTION-GUIDE.md +392 -0
- package/bundled/locales/zh-CN/adoption/STATIC-DYNAMIC-GUIDE.md +302 -0
- package/bundled/locales/zh-CN/adoption/checklists/enterprise.md +332 -0
- package/bundled/locales/zh-CN/adoption/checklists/minimal.md +141 -0
- package/bundled/locales/zh-CN/adoption/checklists/recommended.md +272 -0
- package/bundled/locales/zh-CN/ai/MAINTENANCE.md +739 -0
- package/bundled/locales/zh-CN/ai/options/changelog/auto-generated.ai.yaml +76 -0
- package/bundled/locales/zh-CN/ai/options/changelog/keep-a-changelog.ai.yaml +99 -0
- package/bundled/locales/zh-CN/ai/options/code-review/automated-review.ai.yaml +120 -0
- package/bundled/locales/zh-CN/ai/options/code-review/pair-programming.ai.yaml +109 -0
- package/bundled/locales/zh-CN/ai/options/code-review/pr-review.ai.yaml +104 -0
- package/bundled/locales/zh-CN/ai/options/commit-message/bilingual.ai.yaml +105 -0
- package/bundled/locales/zh-CN/ai/options/commit-message/english.ai.yaml +79 -0
- package/bundled/locales/zh-CN/ai/options/commit-message/traditional-chinese.ai.yaml +100 -0
- package/bundled/locales/zh-CN/ai/options/documentation/api-docs.ai.yaml +140 -0
- package/bundled/locales/zh-CN/ai/options/documentation/markdown-docs.ai.yaml +89 -0
- package/bundled/locales/zh-CN/ai/options/documentation/wiki-style.ai.yaml +119 -0
- package/bundled/locales/zh-CN/ai/options/git-workflow/gitflow.ai.yaml +133 -0
- package/bundled/locales/zh-CN/ai/options/git-workflow/github-flow.ai.yaml +73 -0
- package/bundled/locales/zh-CN/ai/options/git-workflow/merge-commit.ai.yaml +88 -0
- package/bundled/locales/zh-CN/ai/options/git-workflow/rebase-ff.ai.yaml +113 -0
- package/bundled/locales/zh-CN/ai/options/git-workflow/squash-merge.ai.yaml +85 -0
- package/bundled/locales/zh-CN/ai/options/git-workflow/trunk-based.ai.yaml +117 -0
- package/bundled/locales/zh-CN/ai/options/project-structure/dotnet.ai.yaml +108 -0
- package/bundled/locales/zh-CN/ai/options/project-structure/go.ai.yaml +115 -0
- package/bundled/locales/zh-CN/ai/options/project-structure/java.ai.yaml +113 -0
- package/bundled/locales/zh-CN/ai/options/project-structure/kotlin.ai.yaml +123 -0
- package/bundled/locales/zh-CN/ai/options/project-structure/nodejs.ai.yaml +101 -0
- package/bundled/locales/zh-CN/ai/options/project-structure/php.ai.yaml +147 -0
- package/bundled/locales/zh-CN/ai/options/project-structure/python.ai.yaml +116 -0
- package/bundled/locales/zh-CN/ai/options/project-structure/ruby.ai.yaml +140 -0
- package/bundled/locales/zh-CN/ai/options/project-structure/rust.ai.yaml +117 -0
- package/bundled/locales/zh-CN/ai/options/project-structure/swift.ai.yaml +143 -0
- package/bundled/locales/zh-CN/ai/options/testing/contract-testing.ai.yaml +254 -0
- package/bundled/locales/zh-CN/ai/options/testing/e2e-testing.ai.yaml +116 -0
- package/bundled/locales/zh-CN/ai/options/testing/industry-pyramid.ai.yaml +144 -0
- package/bundled/locales/zh-CN/ai/options/testing/integration-testing.ai.yaml +90 -0
- package/bundled/locales/zh-CN/ai/options/testing/istqb-framework.ai.yaml +108 -0
- package/bundled/locales/zh-CN/ai/options/testing/performance-testing.ai.yaml +272 -0
- package/bundled/locales/zh-CN/ai/options/testing/security-testing.ai.yaml +160 -0
- package/bundled/locales/zh-CN/ai/options/testing/system-testing.ai.yaml +101 -0
- package/bundled/locales/zh-CN/ai/options/testing/unit-testing.ai.yaml +82 -0
- package/bundled/locales/zh-CN/ai/standards/anti-hallucination.ai.yaml +145 -0
- package/bundled/locales/zh-CN/ai/standards/changelog.ai.yaml +146 -0
- package/bundled/locales/zh-CN/ai/standards/checkin-standards.ai.yaml +170 -0
- package/bundled/locales/zh-CN/ai/standards/code-review.ai.yaml +148 -0
- package/bundled/locales/zh-CN/ai/standards/commit-message.ai.yaml +175 -0
- package/bundled/locales/zh-CN/ai/standards/documentation-structure.ai.yaml +124 -0
- package/bundled/locales/zh-CN/ai/standards/documentation-writing-standards.ai.yaml +190 -0
- package/bundled/locales/zh-CN/ai/standards/error-codes.ai.yaml +139 -0
- package/bundled/locales/zh-CN/ai/standards/git-workflow.ai.yaml +95 -0
- package/bundled/locales/zh-CN/ai/standards/logging.ai.yaml +128 -0
- package/bundled/locales/zh-CN/ai/standards/project-structure.ai.yaml +134 -0
- package/bundled/locales/zh-CN/ai/standards/spec-driven-development.ai.yaml +169 -0
- package/bundled/locales/zh-CN/ai/standards/test-completeness-dimensions.ai.yaml +220 -0
- package/bundled/locales/zh-CN/ai/standards/testing.ai.yaml +137 -0
- package/bundled/locales/zh-CN/ai/standards/versioning.ai.yaml +211 -0
- package/bundled/locales/zh-CN/core/ai-instruction-standards.md +213 -0
- package/bundled/locales/zh-CN/core/anti-hallucination.md +691 -0
- package/bundled/locales/zh-CN/core/changelog-standards.md +147 -0
- package/bundled/locales/zh-CN/core/checkin-standards.md +943 -0
- package/bundled/locales/zh-CN/core/code-review-guide.md +693 -0
- package/bundled/locales/zh-CN/core/commit-message-guide.md +129 -0
- package/bundled/locales/zh-CN/core/documentation-structure.md +173 -0
- package/bundled/locales/zh-CN/core/documentation-writing-standards.md +495 -0
- package/bundled/locales/zh-CN/core/error-code-standards.md +180 -0
- package/bundled/locales/zh-CN/core/git-workflow.md +193 -0
- package/bundled/locales/zh-CN/core/logging-standards.md +174 -0
- package/bundled/locales/zh-CN/core/project-structure.md +184 -0
- package/bundled/locales/zh-CN/core/refactoring-standards.md +642 -0
- package/bundled/locales/zh-CN/core/spec-driven-development.md +215 -0
- package/bundled/locales/zh-CN/core/test-completeness-dimensions.md +544 -0
- package/bundled/locales/zh-CN/core/test-driven-development.md +1002 -0
- package/bundled/locales/zh-CN/core/testing-standards.md +170 -0
- package/bundled/locales/zh-CN/core/versioning.md +177 -0
- package/bundled/locales/zh-CN/docs/AI-AGENT-ROADMAP.md +303 -0
- package/bundled/locales/zh-CN/docs/CLI-INIT-OPTIONS.md +990 -0
- package/bundled/locales/zh-CN/docs/OPERATION-WORKFLOW.md +1064 -0
- package/bundled/locales/zh-CN/docs/USAGE-MODES-COMPARISON.md +333 -0
- package/bundled/locales/zh-CN/docs/WINDOWS-GUIDE.md +215 -0
- package/bundled/locales/zh-CN/integrations/codex/AGENTS.md +115 -0
- package/bundled/locales/zh-CN/integrations/codex/README.md +67 -0
- package/bundled/locales/zh-CN/integrations/gemini-cli/GEMINI.md +102 -0
- package/bundled/locales/zh-CN/integrations/gemini-cli/README.md +140 -0
- package/bundled/locales/zh-CN/integrations/github-copilot/COPILOT-CHAT-REFERENCE.md +269 -0
- package/bundled/locales/zh-CN/integrations/github-copilot/README.md +167 -0
- package/bundled/locales/zh-CN/integrations/github-copilot/copilot-instructions.md +263 -0
- package/bundled/locales/zh-CN/integrations/github-copilot/skills-mapping.md +192 -0
- package/bundled/locales/zh-CN/integrations/google-antigravity/INSTRUCTIONS.md +61 -0
- package/bundled/locales/zh-CN/integrations/google-antigravity/README.md +84 -0
- package/bundled/locales/zh-CN/integrations/opencode/AGENTS.md +111 -0
- package/bundled/locales/zh-CN/integrations/opencode/README.md +176 -0
- package/bundled/locales/zh-CN/integrations/opencode/skills-mapping.md +396 -0
- package/bundled/locales/zh-CN/integrations/openspec/AGENTS.md +301 -0
- package/bundled/locales/zh-CN/integrations/openspec/README.md +43 -0
- package/bundled/locales/zh-CN/integrations/spec-kit/AGENTS.md +184 -0
- package/bundled/locales/zh-CN/integrations/spec-kit/README.md +43 -0
- package/bundled/locales/zh-CN/options/commit-message/bilingual.md +161 -0
- package/bundled/locales/zh-CN/options/commit-message/english.md +137 -0
- package/bundled/locales/zh-CN/options/commit-message/traditional-chinese.md +162 -0
- package/bundled/locales/zh-CN/options/git-workflow/gitflow.md +147 -0
- package/bundled/locales/zh-CN/options/git-workflow/github-flow.md +124 -0
- package/bundled/locales/zh-CN/options/git-workflow/merge-commit.md +124 -0
- package/bundled/locales/zh-CN/options/git-workflow/rebase-ff.md +160 -0
- package/bundled/locales/zh-CN/options/git-workflow/squash-merge.md +117 -0
- package/bundled/locales/zh-CN/options/git-workflow/trunk-based.md +125 -0
- package/bundled/locales/zh-CN/options/project-structure/dotnet.md +183 -0
- package/bundled/locales/zh-CN/options/project-structure/go.md +226 -0
- package/bundled/locales/zh-CN/options/project-structure/java.md +213 -0
- package/bundled/locales/zh-CN/options/project-structure/nodejs.md +185 -0
- package/bundled/locales/zh-CN/options/project-structure/python.md +229 -0
- package/bundled/locales/zh-CN/options/testing/e2e-testing.md +207 -0
- package/bundled/locales/zh-CN/options/testing/integration-testing.md +230 -0
- package/bundled/locales/zh-CN/options/testing/system-testing.md +183 -0
- package/bundled/locales/zh-CN/options/testing/unit-testing.md +165 -0
- package/bundled/locales/zh-CN/skills/INTEGRATION-GUIDE.md +218 -0
- package/bundled/locales/zh-CN/skills/README.md +134 -0
- package/bundled/locales/zh-CN/skills/_shared/README.md +68 -0
- package/bundled/locales/zh-CN/skills/claude-code/CONTRIBUTING.template.md +151 -0
- package/bundled/locales/zh-CN/skills/claude-code/README.md +174 -0
- package/bundled/locales/zh-CN/skills/claude-code/ai-collaboration-standards/SKILL.md +175 -0
- package/bundled/locales/zh-CN/skills/claude-code/ai-collaboration-standards/anti-hallucination.md +223 -0
- package/bundled/locales/zh-CN/skills/claude-code/ai-collaboration-standards/certainty-labels.md +132 -0
- package/bundled/locales/zh-CN/skills/claude-code/changelog-guide/SKILL.md +237 -0
- package/bundled/locales/zh-CN/skills/claude-code/checkin-assistant/SKILL.md +407 -0
- package/bundled/locales/zh-CN/skills/claude-code/code-review-assistant/SKILL.md +154 -0
- package/bundled/locales/zh-CN/skills/claude-code/code-review-assistant/checkin-checklist.md +257 -0
- package/bundled/locales/zh-CN/skills/claude-code/code-review-assistant/review-checklist.md +246 -0
- package/bundled/locales/zh-CN/skills/claude-code/commands/bdd.md +142 -0
- package/bundled/locales/zh-CN/skills/claude-code/commands/methodology.md +274 -0
- package/bundled/locales/zh-CN/skills/claude-code/commit-standards/SKILL.md +191 -0
- package/bundled/locales/zh-CN/skills/claude-code/commit-standards/conventional-commits.md +264 -0
- package/bundled/locales/zh-CN/skills/claude-code/commit-standards/language-options.md +172 -0
- package/bundled/locales/zh-CN/skills/claude-code/documentation-guide/SKILL.md +421 -0
- package/bundled/locales/zh-CN/skills/claude-code/documentation-guide/documentation-structure.md +357 -0
- package/bundled/locales/zh-CN/skills/claude-code/documentation-guide/readme-template.md +412 -0
- package/bundled/locales/zh-CN/skills/claude-code/error-code-guide/SKILL.md +269 -0
- package/bundled/locales/zh-CN/skills/claude-code/git-workflow-guide/SKILL.md +218 -0
- package/bundled/locales/zh-CN/skills/claude-code/git-workflow-guide/branch-naming.md +220 -0
- package/bundled/locales/zh-CN/skills/claude-code/git-workflow-guide/git-workflow.md +321 -0
- package/bundled/locales/zh-CN/skills/claude-code/logging-guide/SKILL.md +285 -0
- package/bundled/locales/zh-CN/skills/claude-code/methodology-system/SKILL.md +131 -0
- package/bundled/locales/zh-CN/skills/claude-code/methodology-system/create-methodology.md +350 -0
- package/bundled/locales/zh-CN/skills/claude-code/methodology-system/runtime.md +279 -0
- package/bundled/locales/zh-CN/skills/claude-code/project-structure-guide/SKILL.md +143 -0
- package/bundled/locales/zh-CN/skills/claude-code/project-structure-guide/language-patterns.md +271 -0
- package/bundled/locales/zh-CN/skills/claude-code/refactoring-assistant/SKILL.md +162 -0
- package/bundled/locales/zh-CN/skills/claude-code/release-standards/SKILL.md +191 -0
- package/bundled/locales/zh-CN/skills/claude-code/release-standards/changelog-format.md +247 -0
- package/bundled/locales/zh-CN/skills/claude-code/release-standards/release-workflow.md +345 -0
- package/bundled/locales/zh-CN/skills/claude-code/release-standards/semantic-versioning.md +250 -0
- package/bundled/locales/zh-CN/skills/claude-code/requirement-assistant/SKILL.md +227 -0
- package/bundled/locales/zh-CN/skills/claude-code/requirement-assistant/requirement-checklist.md +325 -0
- package/bundled/locales/zh-CN/skills/claude-code/requirement-assistant/requirement-writing.md +399 -0
- package/bundled/locales/zh-CN/skills/claude-code/spec-driven-dev/SKILL.md +243 -0
- package/bundled/locales/zh-CN/skills/claude-code/tdd-assistant/SKILL.md +332 -0
- package/bundled/locales/zh-CN/skills/claude-code/tdd-assistant/language-examples.md +639 -0
- package/bundled/locales/zh-CN/skills/claude-code/tdd-assistant/tdd-workflow.md +486 -0
- package/bundled/locales/zh-CN/skills/claude-code/test-coverage-assistant/SKILL.md +282 -0
- package/bundled/locales/zh-CN/skills/claude-code/testing-guide/SKILL.md +234 -0
- package/bundled/locales/zh-CN/skills/claude-code/testing-guide/testing-pyramid.md +448 -0
- package/bundled/locales/zh-CN/skills/cline/README.md +58 -0
- package/bundled/locales/zh-CN/skills/copilot/README.md +61 -0
- package/bundled/locales/zh-CN/skills/copilot/copilot-instructions.md +79 -0
- package/bundled/locales/zh-CN/skills/cursor/README.md +58 -0
- package/bundled/locales/zh-CN/skills/windsurf/README.md +59 -0
- package/bundled/locales/zh-TW/CHANGELOG.md +707 -0
- package/bundled/locales/zh-TW/CLAUDE.md +213 -0
- package/bundled/locales/zh-TW/MAINTENANCE.md +683 -0
- package/bundled/locales/zh-TW/README.md +687 -0
- package/bundled/locales/zh-TW/STANDARDS-MAPPING.md +177 -0
- package/bundled/locales/zh-TW/adoption/ADOPTION-GUIDE.md +392 -0
- package/bundled/locales/zh-TW/adoption/STATIC-DYNAMIC-GUIDE.md +299 -0
- package/bundled/locales/zh-TW/adoption/checklists/enterprise.md +332 -0
- package/bundled/locales/zh-TW/adoption/checklists/minimal.md +141 -0
- package/bundled/locales/zh-TW/adoption/checklists/recommended.md +272 -0
- package/bundled/locales/zh-TW/ai/MAINTENANCE.md +754 -0
- package/bundled/locales/zh-TW/ai/options/changelog/auto-generated.ai.yaml +76 -0
- package/bundled/locales/zh-TW/ai/options/changelog/keep-a-changelog.ai.yaml +99 -0
- package/bundled/locales/zh-TW/ai/options/code-review/automated-review.ai.yaml +120 -0
- package/bundled/locales/zh-TW/ai/options/code-review/pair-programming.ai.yaml +109 -0
- package/bundled/locales/zh-TW/ai/options/code-review/pr-review.ai.yaml +104 -0
- package/bundled/locales/zh-TW/ai/options/commit-message/bilingual.ai.yaml +105 -0
- package/bundled/locales/zh-TW/ai/options/commit-message/english.ai.yaml +79 -0
- package/bundled/locales/zh-TW/ai/options/commit-message/traditional-chinese.ai.yaml +100 -0
- package/bundled/locales/zh-TW/ai/options/documentation/api-docs.ai.yaml +140 -0
- package/bundled/locales/zh-TW/ai/options/documentation/markdown-docs.ai.yaml +89 -0
- package/bundled/locales/zh-TW/ai/options/documentation/wiki-style.ai.yaml +119 -0
- package/bundled/locales/zh-TW/ai/options/git-workflow/gitflow.ai.yaml +133 -0
- package/bundled/locales/zh-TW/ai/options/git-workflow/github-flow.ai.yaml +73 -0
- package/bundled/locales/zh-TW/ai/options/git-workflow/merge-commit.ai.yaml +88 -0
- package/bundled/locales/zh-TW/ai/options/git-workflow/rebase-ff.ai.yaml +113 -0
- package/bundled/locales/zh-TW/ai/options/git-workflow/squash-merge.ai.yaml +85 -0
- package/bundled/locales/zh-TW/ai/options/git-workflow/trunk-based.ai.yaml +117 -0
- package/bundled/locales/zh-TW/ai/options/project-structure/dotnet.ai.yaml +108 -0
- package/bundled/locales/zh-TW/ai/options/project-structure/go.ai.yaml +115 -0
- package/bundled/locales/zh-TW/ai/options/project-structure/java.ai.yaml +113 -0
- package/bundled/locales/zh-TW/ai/options/project-structure/kotlin.ai.yaml +123 -0
- package/bundled/locales/zh-TW/ai/options/project-structure/nodejs.ai.yaml +101 -0
- package/bundled/locales/zh-TW/ai/options/project-structure/php.ai.yaml +147 -0
- package/bundled/locales/zh-TW/ai/options/project-structure/python.ai.yaml +116 -0
- package/bundled/locales/zh-TW/ai/options/project-structure/ruby.ai.yaml +140 -0
- package/bundled/locales/zh-TW/ai/options/project-structure/rust.ai.yaml +117 -0
- package/bundled/locales/zh-TW/ai/options/project-structure/swift.ai.yaml +143 -0
- package/bundled/locales/zh-TW/ai/options/testing/contract-testing.ai.yaml +254 -0
- package/bundled/locales/zh-TW/ai/options/testing/e2e-testing.ai.yaml +116 -0
- package/bundled/locales/zh-TW/ai/options/testing/industry-pyramid.ai.yaml +144 -0
- package/bundled/locales/zh-TW/ai/options/testing/integration-testing.ai.yaml +90 -0
- package/bundled/locales/zh-TW/ai/options/testing/istqb-framework.ai.yaml +108 -0
- package/bundled/locales/zh-TW/ai/options/testing/performance-testing.ai.yaml +272 -0
- package/bundled/locales/zh-TW/ai/options/testing/security-testing.ai.yaml +160 -0
- package/bundled/locales/zh-TW/ai/options/testing/system-testing.ai.yaml +101 -0
- package/bundled/locales/zh-TW/ai/options/testing/unit-testing.ai.yaml +82 -0
- package/bundled/locales/zh-TW/ai/standards/anti-hallucination.ai.yaml +145 -0
- package/bundled/locales/zh-TW/ai/standards/changelog.ai.yaml +146 -0
- package/bundled/locales/zh-TW/ai/standards/checkin-standards.ai.yaml +170 -0
- package/bundled/locales/zh-TW/ai/standards/code-review.ai.yaml +148 -0
- package/bundled/locales/zh-TW/ai/standards/commit-message.ai.yaml +175 -0
- package/bundled/locales/zh-TW/ai/standards/documentation-structure.ai.yaml +124 -0
- package/bundled/locales/zh-TW/ai/standards/documentation-writing-standards.ai.yaml +190 -0
- package/bundled/locales/zh-TW/ai/standards/error-codes.ai.yaml +139 -0
- package/bundled/locales/zh-TW/ai/standards/git-workflow.ai.yaml +95 -0
- package/bundled/locales/zh-TW/ai/standards/logging.ai.yaml +128 -0
- package/bundled/locales/zh-TW/ai/standards/project-structure.ai.yaml +134 -0
- package/bundled/locales/zh-TW/ai/standards/spec-driven-development.ai.yaml +169 -0
- package/bundled/locales/zh-TW/ai/standards/test-completeness-dimensions.ai.yaml +220 -0
- package/bundled/locales/zh-TW/ai/standards/testing.ai.yaml +137 -0
- package/bundled/locales/zh-TW/ai/standards/versioning.ai.yaml +211 -0
- package/bundled/locales/zh-TW/core/ai-instruction-standards.md +213 -0
- package/bundled/locales/zh-TW/core/anti-hallucination.md +691 -0
- package/bundled/locales/zh-TW/core/changelog-standards.md +564 -0
- package/bundled/locales/zh-TW/core/checkin-standards.md +943 -0
- package/bundled/locales/zh-TW/core/code-review-checklist.md +693 -0
- package/bundled/locales/zh-TW/core/commit-message-guide.md +809 -0
- package/bundled/locales/zh-TW/core/documentation-structure.md +1125 -0
- package/bundled/locales/zh-TW/core/documentation-writing-standards.md +495 -0
- package/bundled/locales/zh-TW/core/error-code-standards.md +384 -0
- package/bundled/locales/zh-TW/core/git-workflow.md +860 -0
- package/bundled/locales/zh-TW/core/logging-standards.md +325 -0
- package/bundled/locales/zh-TW/core/project-structure.md +362 -0
- package/bundled/locales/zh-TW/core/refactoring-standards.md +642 -0
- package/bundled/locales/zh-TW/core/spec-driven-development.md +215 -0
- package/bundled/locales/zh-TW/core/test-completeness-dimensions.md +544 -0
- package/bundled/locales/zh-TW/core/test-driven-development.md +1004 -0
- package/bundled/locales/zh-TW/core/testing-standards.md +2158 -0
- package/bundled/locales/zh-TW/core/versioning.md +909 -0
- package/bundled/locales/zh-TW/docs/AI-AGENT-ROADMAP.md +303 -0
- package/bundled/locales/zh-TW/docs/CLI-INIT-OPTIONS.md +990 -0
- package/bundled/locales/zh-TW/docs/OPERATION-WORKFLOW.md +1064 -0
- package/bundled/locales/zh-TW/docs/USAGE-MODES-COMPARISON.md +333 -0
- package/bundled/locales/zh-TW/docs/WINDOWS-GUIDE.md +215 -0
- package/bundled/locales/zh-TW/integrations/codex/AGENTS.md +115 -0
- package/bundled/locales/zh-TW/integrations/codex/README.md +113 -0
- package/bundled/locales/zh-TW/integrations/gemini-cli/GEMINI.md +102 -0
- package/bundled/locales/zh-TW/integrations/gemini-cli/README.md +140 -0
- package/bundled/locales/zh-TW/integrations/github-copilot/COPILOT-CHAT-REFERENCE.md +269 -0
- package/bundled/locales/zh-TW/integrations/github-copilot/README.md +167 -0
- package/bundled/locales/zh-TW/integrations/github-copilot/copilot-instructions.md +263 -0
- package/bundled/locales/zh-TW/integrations/github-copilot/skills-mapping.md +192 -0
- package/bundled/locales/zh-TW/integrations/google-antigravity/INSTRUCTIONS.md +61 -0
- package/bundled/locales/zh-TW/integrations/google-antigravity/README.md +84 -0
- package/bundled/locales/zh-TW/integrations/opencode/AGENTS.md +111 -0
- package/bundled/locales/zh-TW/integrations/opencode/README.md +176 -0
- package/bundled/locales/zh-TW/integrations/opencode/skills-mapping.md +396 -0
- package/bundled/locales/zh-TW/integrations/openspec/AGENTS.md +301 -0
- package/bundled/locales/zh-TW/integrations/openspec/README.md +43 -0
- package/bundled/locales/zh-TW/integrations/spec-kit/AGENTS.md +184 -0
- package/bundled/locales/zh-TW/integrations/spec-kit/README.md +43 -0
- package/bundled/locales/zh-TW/options/commit-message/bilingual.md +161 -0
- package/bundled/locales/zh-TW/options/commit-message/english.md +137 -0
- package/bundled/locales/zh-TW/options/commit-message/traditional-chinese.md +162 -0
- package/bundled/locales/zh-TW/options/git-workflow/gitflow.md +147 -0
- package/bundled/locales/zh-TW/options/git-workflow/github-flow.md +124 -0
- package/bundled/locales/zh-TW/options/git-workflow/merge-commit.md +124 -0
- package/bundled/locales/zh-TW/options/git-workflow/rebase-ff.md +160 -0
- package/bundled/locales/zh-TW/options/git-workflow/squash-merge.md +117 -0
- package/bundled/locales/zh-TW/options/git-workflow/trunk-based.md +125 -0
- package/bundled/locales/zh-TW/options/project-structure/dotnet.md +183 -0
- package/bundled/locales/zh-TW/options/project-structure/go.md +226 -0
- package/bundled/locales/zh-TW/options/project-structure/java.md +213 -0
- package/bundled/locales/zh-TW/options/project-structure/nodejs.md +185 -0
- package/bundled/locales/zh-TW/options/project-structure/python.md +229 -0
- package/bundled/locales/zh-TW/options/testing/e2e-testing.md +207 -0
- package/bundled/locales/zh-TW/options/testing/integration-testing.md +230 -0
- package/bundled/locales/zh-TW/options/testing/system-testing.md +183 -0
- package/bundled/locales/zh-TW/options/testing/unit-testing.md +165 -0
- package/bundled/locales/zh-TW/skills/INTEGRATION-GUIDE.md +218 -0
- package/bundled/locales/zh-TW/skills/README.md +132 -0
- package/bundled/locales/zh-TW/skills/_shared/README.md +68 -0
- package/bundled/locales/zh-TW/skills/claude-code/CONTRIBUTING.template.md +151 -0
- package/bundled/locales/zh-TW/skills/claude-code/README.md +174 -0
- package/bundled/locales/zh-TW/skills/claude-code/ai-collaboration-standards/SKILL.md +175 -0
- package/bundled/locales/zh-TW/skills/claude-code/ai-collaboration-standards/anti-hallucination.md +223 -0
- package/bundled/locales/zh-TW/skills/claude-code/ai-collaboration-standards/certainty-labels.md +132 -0
- package/bundled/locales/zh-TW/skills/claude-code/changelog-guide/SKILL.md +237 -0
- package/bundled/locales/zh-TW/skills/claude-code/checkin-assistant/SKILL.md +407 -0
- package/bundled/locales/zh-TW/skills/claude-code/code-review-assistant/SKILL.md +154 -0
- package/bundled/locales/zh-TW/skills/claude-code/code-review-assistant/checkin-checklist.md +257 -0
- package/bundled/locales/zh-TW/skills/claude-code/code-review-assistant/review-checklist.md +246 -0
- package/bundled/locales/zh-TW/skills/claude-code/commands/bdd.md +142 -0
- package/bundled/locales/zh-TW/skills/claude-code/commands/methodology.md +274 -0
- package/bundled/locales/zh-TW/skills/claude-code/commit-standards/SKILL.md +191 -0
- package/bundled/locales/zh-TW/skills/claude-code/commit-standards/conventional-commits.md +264 -0
- package/bundled/locales/zh-TW/skills/claude-code/commit-standards/language-options.md +172 -0
- package/bundled/locales/zh-TW/skills/claude-code/documentation-guide/SKILL.md +421 -0
- package/bundled/locales/zh-TW/skills/claude-code/documentation-guide/documentation-structure.md +357 -0
- package/bundled/locales/zh-TW/skills/claude-code/documentation-guide/readme-template.md +412 -0
- package/bundled/locales/zh-TW/skills/claude-code/error-code-guide/SKILL.md +269 -0
- package/bundled/locales/zh-TW/skills/claude-code/git-workflow-guide/SKILL.md +218 -0
- package/bundled/locales/zh-TW/skills/claude-code/git-workflow-guide/branch-naming.md +220 -0
- package/bundled/locales/zh-TW/skills/claude-code/git-workflow-guide/git-workflow.md +321 -0
- package/bundled/locales/zh-TW/skills/claude-code/logging-guide/SKILL.md +285 -0
- package/bundled/locales/zh-TW/skills/claude-code/methodology-system/SKILL.md +131 -0
- package/bundled/locales/zh-TW/skills/claude-code/methodology-system/create-methodology.md +350 -0
- package/bundled/locales/zh-TW/skills/claude-code/methodology-system/runtime.md +279 -0
- package/bundled/locales/zh-TW/skills/claude-code/project-structure-guide/SKILL.md +143 -0
- package/bundled/locales/zh-TW/skills/claude-code/project-structure-guide/language-patterns.md +271 -0
- package/bundled/locales/zh-TW/skills/claude-code/refactoring-assistant/SKILL.md +162 -0
- package/bundled/locales/zh-TW/skills/claude-code/release-standards/SKILL.md +191 -0
- package/bundled/locales/zh-TW/skills/claude-code/release-standards/changelog-format.md +247 -0
- package/bundled/locales/zh-TW/skills/claude-code/release-standards/release-workflow.md +345 -0
- package/bundled/locales/zh-TW/skills/claude-code/release-standards/semantic-versioning.md +250 -0
- package/bundled/locales/zh-TW/skills/claude-code/requirement-assistant/SKILL.md +227 -0
- package/bundled/locales/zh-TW/skills/claude-code/requirement-assistant/requirement-checklist.md +325 -0
- package/bundled/locales/zh-TW/skills/claude-code/requirement-assistant/requirement-writing.md +399 -0
- package/bundled/locales/zh-TW/skills/claude-code/spec-driven-dev/SKILL.md +243 -0
- package/bundled/locales/zh-TW/skills/claude-code/tdd-assistant/SKILL.md +332 -0
- package/bundled/locales/zh-TW/skills/claude-code/tdd-assistant/language-examples.md +639 -0
- package/bundled/locales/zh-TW/skills/claude-code/tdd-assistant/tdd-workflow.md +486 -0
- package/bundled/locales/zh-TW/skills/claude-code/test-coverage-assistant/SKILL.md +282 -0
- package/bundled/locales/zh-TW/skills/claude-code/testing-guide/SKILL.md +234 -0
- package/bundled/locales/zh-TW/skills/claude-code/testing-guide/testing-pyramid.md +448 -0
- package/bundled/locales/zh-TW/skills/cline/README.md +58 -0
- package/bundled/locales/zh-TW/skills/copilot/README.md +61 -0
- package/bundled/locales/zh-TW/skills/copilot/copilot-instructions.md +79 -0
- package/bundled/locales/zh-TW/skills/cursor/README.md +58 -0
- package/bundled/locales/zh-TW/skills/windsurf/README.md +59 -0
- package/bundled/skills/claude-code/CONTRIBUTING.template.md +141 -0
- package/bundled/skills/claude-code/README.md +196 -0
- package/bundled/skills/claude-code/ai/standards/checkin.ai.yaml +21 -0
- package/bundled/skills/claude-code/ai/standards/commit.ai.yaml +20 -0
- package/bundled/skills/claude-code/ai/standards/refactoring.ai.yaml +34 -0
- package/bundled/skills/claude-code/ai/standards/testing.ai.yaml +41 -0
- package/bundled/skills/claude-code/ai-collaboration-standards/SKILL.md +175 -0
- package/bundled/skills/claude-code/ai-collaboration-standards/anti-hallucination.md +215 -0
- package/bundled/skills/claude-code/ai-collaboration-standards/certainty-labels.md +124 -0
- package/bundled/skills/claude-code/changelog-guide/SKILL.md +232 -0
- package/bundled/skills/claude-code/checkin-assistant/SKILL.md +402 -0
- package/bundled/skills/claude-code/code-review-assistant/SKILL.md +220 -0
- package/bundled/skills/claude-code/code-review-assistant/checkin-checklist.md +249 -0
- package/bundled/skills/claude-code/code-review-assistant/review-checklist.md +238 -0
- package/bundled/skills/claude-code/commands/README.md +78 -0
- package/bundled/skills/claude-code/commands/bdd.md +142 -0
- package/bundled/skills/claude-code/commands/changelog.md +57 -0
- package/bundled/skills/claude-code/commands/check.md +91 -0
- package/bundled/skills/claude-code/commands/commit.md +48 -0
- package/bundled/skills/claude-code/commands/config.md +97 -0
- package/bundled/skills/claude-code/commands/coverage.md +58 -0
- package/bundled/skills/claude-code/commands/docs.md +75 -0
- package/bundled/skills/claude-code/commands/init.md +88 -0
- package/bundled/skills/claude-code/commands/methodology.md +268 -0
- package/bundled/skills/claude-code/commands/release.md +50 -0
- package/bundled/skills/claude-code/commands/requirement.md +54 -0
- package/bundled/skills/claude-code/commands/review.md +50 -0
- package/bundled/skills/claude-code/commands/spec.md +69 -0
- package/bundled/skills/claude-code/commands/tdd.md +86 -0
- package/bundled/skills/claude-code/commands/update.md +122 -0
- package/bundled/skills/claude-code/commit-standards/SKILL.md +249 -0
- package/bundled/skills/claude-code/commit-standards/conventional-commits.md +256 -0
- package/bundled/skills/claude-code/commit-standards/language-options.md +164 -0
- package/bundled/skills/claude-code/documentation-guide/SKILL.md +416 -0
- package/bundled/skills/claude-code/documentation-guide/documentation-structure.md +349 -0
- package/bundled/skills/claude-code/documentation-guide/readme-template.md +404 -0
- package/bundled/skills/claude-code/error-code-guide/SKILL.md +264 -0
- package/bundled/skills/claude-code/git-workflow-guide/SKILL.md +226 -0
- package/bundled/skills/claude-code/git-workflow-guide/branch-naming.md +212 -0
- package/bundled/skills/claude-code/git-workflow-guide/git-workflow.md +313 -0
- package/bundled/skills/claude-code/logging-guide/SKILL.md +280 -0
- package/bundled/skills/claude-code/methodology-system/SKILL.md +215 -0
- package/bundled/skills/claude-code/methodology-system/create-methodology.md +450 -0
- package/bundled/skills/claude-code/methodology-system/runtime.md +271 -0
- package/bundled/skills/claude-code/project-structure-guide/SKILL.md +143 -0
- package/bundled/skills/claude-code/project-structure-guide/language-patterns.md +263 -0
- package/bundled/skills/claude-code/refactoring-assistant/SKILL.md +205 -0
- package/bundled/skills/claude-code/release-standards/SKILL.md +191 -0
- package/bundled/skills/claude-code/release-standards/changelog-format.md +239 -0
- package/bundled/skills/claude-code/release-standards/release-workflow.md +337 -0
- package/bundled/skills/claude-code/release-standards/semantic-versioning.md +242 -0
- package/bundled/skills/claude-code/requirement-assistant/SKILL.md +222 -0
- package/bundled/skills/claude-code/requirement-assistant/requirement-checklist.md +317 -0
- package/bundled/skills/claude-code/requirement-assistant/requirement-writing.md +391 -0
- package/bundled/skills/claude-code/spec-driven-dev/SKILL.md +238 -0
- package/bundled/skills/claude-code/tdd-assistant/SKILL.md +384 -0
- package/bundled/skills/claude-code/tdd-assistant/language-examples.md +1276 -0
- package/bundled/skills/claude-code/tdd-assistant/tdd-workflow.md +659 -0
- package/bundled/skills/claude-code/test-coverage-assistant/SKILL.md +277 -0
- package/bundled/skills/claude-code/testing-guide/SKILL.md +317 -0
- package/bundled/skills/claude-code/testing-guide/testing-pyramid.md +440 -0
- package/package.json +4 -2
- package/src/commands/check.js +38 -6
- package/src/commands/init.js +20 -6
- package/src/commands/list.js +7 -2
- package/src/commands/skills.js +0 -2
- package/src/commands/update.js +271 -0
- package/src/i18n/messages.js +161 -11
- package/src/utils/copier.js +63 -10
- package/src/utils/skills-installer.js +47 -11
- package/standards-registry.json +6 -3
|
@@ -0,0 +1,384 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: tdd-assistant
|
|
3
|
+
description: |
|
|
4
|
+
Guide developers through Test-Driven Development workflow.
|
|
5
|
+
Use when: writing tests first, practicing TDD, red-green-refactor cycle, BDD scenarios.
|
|
6
|
+
Keywords: TDD, test first, red green refactor, FIRST, BDD, ATDD, 測試驅動開發, 紅綠重構.
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
# TDD Assistant
|
|
10
|
+
|
|
11
|
+
> **Language**: English | [繁體中文](../../../locales/zh-TW/skills/claude-code/tdd-assistant/SKILL.md)
|
|
12
|
+
|
|
13
|
+
**Version**: 1.0.0
|
|
14
|
+
**Last Updated**: 2026-01-07
|
|
15
|
+
**Applicability**: Claude Code Skills
|
|
16
|
+
|
|
17
|
+
---
|
|
18
|
+
|
|
19
|
+
## Purpose
|
|
20
|
+
|
|
21
|
+
This skill guides developers through the Test-Driven Development workflow, helping them:
|
|
22
|
+
- Write effective failing tests (Red phase)
|
|
23
|
+
- Implement minimum code to pass tests (Green phase)
|
|
24
|
+
- Refactor safely while keeping tests green (Refactor phase)
|
|
25
|
+
- Identify and avoid common TDD anti-patterns
|
|
26
|
+
- Integrate TDD with BDD and ATDD approaches
|
|
27
|
+
- Apply TDD appropriately based on context
|
|
28
|
+
|
|
29
|
+
---
|
|
30
|
+
|
|
31
|
+
## Quick Reference
|
|
32
|
+
|
|
33
|
+
### TDD Cycle Checklist
|
|
34
|
+
|
|
35
|
+
```
|
|
36
|
+
┌─────────────────────────────────────────────────────────────────┐
|
|
37
|
+
│ 🔴 RED Phase │
|
|
38
|
+
│ □ Test describes expected behavior, not implementation │
|
|
39
|
+
│ □ Test name clearly states what is being tested │
|
|
40
|
+
│ □ Test follows AAA pattern (Arrange-Act-Assert) │
|
|
41
|
+
│ □ Test fails for the RIGHT reason │
|
|
42
|
+
│ □ Failure message is clear and actionable │
|
|
43
|
+
├─────────────────────────────────────────────────────────────────┤
|
|
44
|
+
│ 🟢 GREEN Phase │
|
|
45
|
+
│ □ Write MINIMUM code to pass the test │
|
|
46
|
+
│ □ "Fake it" is acceptable (hardcode if needed) │
|
|
47
|
+
│ □ Don't optimize or over-engineer │
|
|
48
|
+
│ □ Test now passes │
|
|
49
|
+
│ □ All other tests still pass │
|
|
50
|
+
├─────────────────────────────────────────────────────────────────┤
|
|
51
|
+
│ 🔵 REFACTOR Phase │
|
|
52
|
+
│ □ Remove duplication (DRY) │
|
|
53
|
+
│ □ Improve naming │
|
|
54
|
+
│ □ Extract methods if needed │
|
|
55
|
+
│ □ Run tests after EVERY change │
|
|
56
|
+
│ □ No new functionality added │
|
|
57
|
+
│ □ All tests still pass │
|
|
58
|
+
└─────────────────────────────────────────────────────────────────┘
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
### FIRST Principles Quick Reference
|
|
62
|
+
|
|
63
|
+
| Principle | Check | Common Violations |
|
|
64
|
+
|-----------|-------|-------------------|
|
|
65
|
+
| **F**ast | < 100ms per unit test | Database calls, file I/O, network |
|
|
66
|
+
| **I**ndependent | No shared state | Static variables, execution order dependency |
|
|
67
|
+
| **R**epeatable | Same result always | DateTime.Now, Random, external services |
|
|
68
|
+
| **S**elf-validating | Clear pass/fail | Manual log checking, no assertions |
|
|
69
|
+
| **T**imely | Test before code | Writing tests after implementation |
|
|
70
|
+
|
|
71
|
+
### Anti-Pattern Quick Detection
|
|
72
|
+
|
|
73
|
+
| Symptom | Likely Anti-Pattern | Quick Fix |
|
|
74
|
+
|---------|---------------------|-----------|
|
|
75
|
+
| Tests break on refactoring | Testing implementation details | Test behavior only |
|
|
76
|
+
| Tests pass but bugs in prod | Over-mocking | Add integration tests |
|
|
77
|
+
| Random test failures | Test interdependence | Isolate test state |
|
|
78
|
+
| Slow test suite | Too many integration tests | Increase unit test ratio |
|
|
79
|
+
| Team avoids writing tests | Complex test setup | Simplify with builders |
|
|
80
|
+
|
|
81
|
+
---
|
|
82
|
+
|
|
83
|
+
## TDD vs BDD vs ATDD Quick Reference
|
|
84
|
+
|
|
85
|
+
| Aspect | TDD | BDD | ATDD |
|
|
86
|
+
|--------|-----|-----|------|
|
|
87
|
+
| **Who writes** | Developers | Developers + BA + QA | All stakeholders |
|
|
88
|
+
| **Language** | Code | Gherkin (Given-When-Then) | Business language |
|
|
89
|
+
| **Level** | Unit/Component | Feature/Scenario | Acceptance |
|
|
90
|
+
| **When** | During coding | Before coding | Before sprint |
|
|
91
|
+
|
|
92
|
+
### When to Use Which
|
|
93
|
+
|
|
94
|
+
```
|
|
95
|
+
Is it a technical implementation detail?
|
|
96
|
+
├─ Yes → TDD
|
|
97
|
+
└─ No → Is there a business stakeholder?
|
|
98
|
+
├─ Yes → Does stakeholder need to read/validate tests?
|
|
99
|
+
│ ├─ Yes → ATDD → BDD → TDD
|
|
100
|
+
│ └─ No → BDD → TDD
|
|
101
|
+
└─ No → TDD
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
---
|
|
105
|
+
|
|
106
|
+
## Workflow Assistance
|
|
107
|
+
|
|
108
|
+
### Red Phase Guidance
|
|
109
|
+
|
|
110
|
+
When writing a failing test, ensure:
|
|
111
|
+
|
|
112
|
+
1. **Clear Intent**
|
|
113
|
+
```typescript
|
|
114
|
+
// ❌ Vague
|
|
115
|
+
test('it works', () => { ... });
|
|
116
|
+
|
|
117
|
+
// ✅ Clear
|
|
118
|
+
test('should calculate discount when order total exceeds threshold', () => { ... });
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
2. **Single Behavior**
|
|
122
|
+
```typescript
|
|
123
|
+
// ❌ Multiple behaviors
|
|
124
|
+
test('should validate and save user', () => { ... });
|
|
125
|
+
|
|
126
|
+
// ✅ Single behavior
|
|
127
|
+
test('should reject invalid email format', () => { ... });
|
|
128
|
+
test('should save user with valid data', () => { ... });
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
3. **Proper Assertions**
|
|
132
|
+
```typescript
|
|
133
|
+
// ❌ No assertion
|
|
134
|
+
test('should process order', () => {
|
|
135
|
+
orderService.process(order);
|
|
136
|
+
// Missing assertion!
|
|
137
|
+
});
|
|
138
|
+
|
|
139
|
+
// ✅ Clear assertion
|
|
140
|
+
test('should mark order as processed', () => {
|
|
141
|
+
const result = orderService.process(order);
|
|
142
|
+
expect(result.status).toBe('processed');
|
|
143
|
+
});
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
### Green Phase Guidance
|
|
147
|
+
|
|
148
|
+
When making tests pass, remember:
|
|
149
|
+
|
|
150
|
+
1. **Minimum Implementation**
|
|
151
|
+
```typescript
|
|
152
|
+
// Test: should return "FizzBuzz" for numbers divisible by both 3 and 5
|
|
153
|
+
|
|
154
|
+
// ❌ Over-engineered first pass
|
|
155
|
+
function fizzBuzz(n: number): string {
|
|
156
|
+
const divisibleBy3 = n % 3 === 0;
|
|
157
|
+
const divisibleBy5 = n % 5 === 0;
|
|
158
|
+
if (divisibleBy3 && divisibleBy5) return 'FizzBuzz';
|
|
159
|
+
if (divisibleBy3) return 'Fizz';
|
|
160
|
+
if (divisibleBy5) return 'Buzz';
|
|
161
|
+
return n.toString();
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
// ✅ Minimum for current test (fake it!)
|
|
165
|
+
function fizzBuzz(n: number): string {
|
|
166
|
+
return 'FizzBuzz'; // Just enough to pass THIS test
|
|
167
|
+
}
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
2. **Progressive Generalization**
|
|
171
|
+
- First test: Hardcode the answer
|
|
172
|
+
- Second test: Add simple conditional
|
|
173
|
+
- Third test: Generalize the pattern
|
|
174
|
+
|
|
175
|
+
### Refactor Phase Guidance
|
|
176
|
+
|
|
177
|
+
Safe refactoring checklist:
|
|
178
|
+
|
|
179
|
+
```
|
|
180
|
+
Before:
|
|
181
|
+
□ All tests are GREEN
|
|
182
|
+
□ Understand what the code does
|
|
183
|
+
|
|
184
|
+
During (one at a time):
|
|
185
|
+
□ Extract method → Run tests
|
|
186
|
+
□ Rename → Run tests
|
|
187
|
+
□ Remove duplication → Run tests
|
|
188
|
+
□ Simplify conditional → Run tests
|
|
189
|
+
|
|
190
|
+
After:
|
|
191
|
+
□ All tests still GREEN
|
|
192
|
+
□ Code is cleaner
|
|
193
|
+
□ No new functionality
|
|
194
|
+
```
|
|
195
|
+
|
|
196
|
+
---
|
|
197
|
+
|
|
198
|
+
## Integration with SDD
|
|
199
|
+
|
|
200
|
+
When working with Spec-Driven Development:
|
|
201
|
+
|
|
202
|
+
### Spec → Test Mapping
|
|
203
|
+
|
|
204
|
+
| Spec Section | Test Type |
|
|
205
|
+
|--------------|-----------|
|
|
206
|
+
| Acceptance Criteria | Acceptance tests (ATDD/BDD) |
|
|
207
|
+
| Business Rules | Unit tests (TDD) |
|
|
208
|
+
| Edge Cases | Unit tests (TDD) |
|
|
209
|
+
| Integration Points | Integration tests |
|
|
210
|
+
|
|
211
|
+
### Workflow
|
|
212
|
+
|
|
213
|
+
```
|
|
214
|
+
1. Read Spec (SPEC-XXX)
|
|
215
|
+
↓
|
|
216
|
+
2. Identify Acceptance Criteria
|
|
217
|
+
↓
|
|
218
|
+
3. Write BDD scenarios (if applicable)
|
|
219
|
+
↓
|
|
220
|
+
4. For each scenario:
|
|
221
|
+
├─ TDD: Red → Green → Refactor
|
|
222
|
+
└─ Mark AC as implemented
|
|
223
|
+
↓
|
|
224
|
+
5. All ACs implemented?
|
|
225
|
+
├─ Yes → Mark Spec as complete
|
|
226
|
+
└─ No → Return to step 4
|
|
227
|
+
```
|
|
228
|
+
|
|
229
|
+
### Test File Reference
|
|
230
|
+
|
|
231
|
+
```typescript
|
|
232
|
+
/**
|
|
233
|
+
* Tests for SPEC-001: User Authentication
|
|
234
|
+
*
|
|
235
|
+
* Acceptance Criteria:
|
|
236
|
+
* - AC-1: User can login with valid credentials
|
|
237
|
+
* - AC-2: Invalid password shows error
|
|
238
|
+
* - AC-3: Account locks after 3 failed attempts
|
|
239
|
+
*/
|
|
240
|
+
describe('User Authentication (SPEC-001)', () => {
|
|
241
|
+
// Tests organized by AC
|
|
242
|
+
});
|
|
243
|
+
```
|
|
244
|
+
|
|
245
|
+
---
|
|
246
|
+
|
|
247
|
+
## Configuration Detection
|
|
248
|
+
|
|
249
|
+
This skill supports project-specific configuration.
|
|
250
|
+
|
|
251
|
+
### Detection Order
|
|
252
|
+
|
|
253
|
+
1. Check `CONTRIBUTING.md` for "Disabled Skills" section
|
|
254
|
+
- If this skill is listed, it is disabled for this project
|
|
255
|
+
2. Check `CONTRIBUTING.md` for "TDD Standards" section
|
|
256
|
+
3. Check for existing test patterns in the codebase
|
|
257
|
+
4. If not found, **default to standard TDD practices**
|
|
258
|
+
|
|
259
|
+
### First-Time Setup
|
|
260
|
+
|
|
261
|
+
If no configuration found and context is unclear:
|
|
262
|
+
|
|
263
|
+
1. Ask: "This project hasn't configured TDD preferences. Which approach do you prefer?"
|
|
264
|
+
- Pure TDD (Red-Green-Refactor)
|
|
265
|
+
- BDD-style TDD (Given-When-Then)
|
|
266
|
+
- ATDD with BDD and TDD
|
|
267
|
+
|
|
268
|
+
2. After selection, suggest documenting in `CONTRIBUTING.md`:
|
|
269
|
+
|
|
270
|
+
```markdown
|
|
271
|
+
## TDD Standards
|
|
272
|
+
|
|
273
|
+
### Preferred Approach
|
|
274
|
+
- Primary: TDD (Red-Green-Refactor)
|
|
275
|
+
- For features with business stakeholders: BDD
|
|
276
|
+
|
|
277
|
+
### Test Naming Convention
|
|
278
|
+
- Pattern: `should_[behavior]_when_[condition]`
|
|
279
|
+
- Example: `should_return_error_when_email_invalid`
|
|
280
|
+
|
|
281
|
+
### Coverage Targets
|
|
282
|
+
- Unit: 80%
|
|
283
|
+
- Integration: 60%
|
|
284
|
+
```
|
|
285
|
+
|
|
286
|
+
---
|
|
287
|
+
|
|
288
|
+
## Detailed Guidelines
|
|
289
|
+
|
|
290
|
+
For complete standards, see:
|
|
291
|
+
- [TDD Core Standard](../../../core/test-driven-development.md)
|
|
292
|
+
- [TDD Workflow Guide](./tdd-workflow.md)
|
|
293
|
+
- [Language Examples](./language-examples.md)
|
|
294
|
+
|
|
295
|
+
For related testing standards:
|
|
296
|
+
- [Testing Standards](../../../core/testing-standards.md)
|
|
297
|
+
- [Test Completeness Dimensions](../../../core/test-completeness-dimensions.md)
|
|
298
|
+
|
|
299
|
+
---
|
|
300
|
+
|
|
301
|
+
## Refactor Phase Deep Dive (YAML Compressed)
|
|
302
|
+
|
|
303
|
+
```yaml
|
|
304
|
+
# === TDD REFACTOR = SAFE SMALL REFACTORING ===
|
|
305
|
+
refactor_phase:
|
|
306
|
+
scope: "Single method/class improvements"
|
|
307
|
+
duration: "5-15 minutes max"
|
|
308
|
+
prerequisite: "All tests GREEN"
|
|
309
|
+
rule: "No new functionality"
|
|
310
|
+
|
|
311
|
+
techniques:
|
|
312
|
+
safe_refactorings:
|
|
313
|
+
- extract_method: "Long method → smaller methods"
|
|
314
|
+
- rename: "Improve naming clarity"
|
|
315
|
+
- inline_variable: "Remove unnecessary temp"
|
|
316
|
+
- replace_magic_number: "Constant with meaning"
|
|
317
|
+
- extract_class: "SRP violation fix"
|
|
318
|
+
- move_method: "Better cohesion"
|
|
319
|
+
|
|
320
|
+
workflow:
|
|
321
|
+
steps:
|
|
322
|
+
1: "Confirm all tests GREEN"
|
|
323
|
+
2: "Make ONE small change"
|
|
324
|
+
3: "Run tests immediately"
|
|
325
|
+
4: "If RED → revert, try smaller step"
|
|
326
|
+
5: "If GREEN → commit, repeat"
|
|
327
|
+
|
|
328
|
+
# === WHEN TO USE /refactor INSTEAD ===
|
|
329
|
+
escalation:
|
|
330
|
+
use_tdd_refactor:
|
|
331
|
+
- "Improving code just written"
|
|
332
|
+
- "Single method/class cleanup"
|
|
333
|
+
- "Takes <15 minutes"
|
|
334
|
+
use_refactoring_assistant:
|
|
335
|
+
- "Legacy code modernization"
|
|
336
|
+
- "Refactor vs Rewrite decision"
|
|
337
|
+
- "Large-scale architectural change"
|
|
338
|
+
- "Technical debt management"
|
|
339
|
+
- "Strangler Fig pattern needed"
|
|
340
|
+
|
|
341
|
+
# === REFACTOR ANTIPATTERNS ===
|
|
342
|
+
antipatterns:
|
|
343
|
+
- name: "Refactoring without tests"
|
|
344
|
+
symptom: "No safety net"
|
|
345
|
+
fix: "Add characterization tests first"
|
|
346
|
+
- name: "Too large refactoring"
|
|
347
|
+
symptom: "Tests RED for hours"
|
|
348
|
+
fix: "Smaller steps, commit frequently"
|
|
349
|
+
- name: "Adding features while refactoring"
|
|
350
|
+
symptom: "Scope creep"
|
|
351
|
+
fix: "Separate commits: refactor then feature"
|
|
352
|
+
- name: "Refactoring everything"
|
|
353
|
+
symptom: "Perfectionism paralysis"
|
|
354
|
+
fix: "Only refactor code you're changing"
|
|
355
|
+
```
|
|
356
|
+
|
|
357
|
+
---
|
|
358
|
+
|
|
359
|
+
## Related Standards
|
|
360
|
+
|
|
361
|
+
- [Test-Driven Development](../../../core/test-driven-development.md) - Core TDD standard
|
|
362
|
+
- [Refactoring Standards](../../../core/refactoring-standards.md) - Large-scale refactoring
|
|
363
|
+
- [Testing Standards](../../../core/testing-standards.md) - Testing framework
|
|
364
|
+
- [Test Completeness Dimensions](../../../core/test-completeness-dimensions.md) - 7 dimensions
|
|
365
|
+
- [Spec-Driven Development](../../../core/spec-driven-development.md) - SDD integration
|
|
366
|
+
- [Testing Guide Skill](../testing-guide/SKILL.md) - Testing guide
|
|
367
|
+
- [Test Coverage Assistant](../test-coverage-assistant/SKILL.md) - Coverage assistance
|
|
368
|
+
- [Refactoring Assistant](../refactoring-assistant/SKILL.md) - Large-scale refactoring
|
|
369
|
+
|
|
370
|
+
---
|
|
371
|
+
|
|
372
|
+
## Version History
|
|
373
|
+
|
|
374
|
+
| Version | Date | Changes |
|
|
375
|
+
|---------|------|---------|
|
|
376
|
+
| 1.0.0 | 2026-01-07 | Initial release |
|
|
377
|
+
|
|
378
|
+
---
|
|
379
|
+
|
|
380
|
+
## License
|
|
381
|
+
|
|
382
|
+
This skill is released under [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/).
|
|
383
|
+
|
|
384
|
+
**Source**: [universal-dev-standards](https://github.com/AsiaOstrich/universal-dev-standards)
|