universal-dev-standards 4.2.0 → 5.0.0-beta.10

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.
Files changed (542) hide show
  1. package/README.md +3 -3
  2. package/bin/uds.js +165 -5
  3. package/bundled/core/acceptance-test-driven-development.md +19 -721
  4. package/bundled/core/accessibility-standards.md +862 -0
  5. package/bundled/core/ai-agreement-standards.md +95 -0
  6. package/bundled/core/ai-friendly-architecture.md +2 -0
  7. package/bundled/core/ai-instruction-standards.md +2 -0
  8. package/bundled/core/anti-hallucination.md +90 -637
  9. package/bundled/core/behavior-driven-development.md +20 -735
  10. package/bundled/core/changelog-standards.md +4 -0
  11. package/bundled/core/checkin-standards.md +21 -4
  12. package/bundled/core/code-review-checklist.md +3 -0
  13. package/bundled/core/commit-message-guide.md +14 -3
  14. package/bundled/core/deployment-standards.md +296 -0
  15. package/bundled/core/developer-memory.md +568 -0
  16. package/bundled/core/documentation-structure.md +114 -18
  17. package/bundled/core/documentation-writing-standards.md +272 -2
  18. package/bundled/core/error-code-standards.md +3 -0
  19. package/bundled/core/forward-derivation-standards.md +134 -8
  20. package/bundled/core/git-workflow.md +72 -686
  21. package/bundled/core/guides/anti-hallucination-guide.md +517 -0
  22. package/bundled/core/guides/git-workflow-guide.md +954 -0
  23. package/bundled/core/guides/performance-guide.md +508 -0
  24. package/bundled/core/guides/refactoring-guide.md +608 -0
  25. package/bundled/core/guides/security-guide.md +485 -0
  26. package/bundled/core/logging-standards.md +337 -2
  27. package/bundled/core/performance-standards.md +231 -0
  28. package/bundled/core/project-context-memory.md +180 -0
  29. package/bundled/core/project-structure.md +315 -2
  30. package/bundled/core/refactoring-standards.md +81 -761
  31. package/bundled/core/requirement-engineering.md +39 -0
  32. package/bundled/core/reverse-engineering-standards.md +6 -4
  33. package/bundled/core/security-standards.md +244 -0
  34. package/bundled/core/spec-driven-development.md +20 -319
  35. package/bundled/core/test-completeness-dimensions.md +213 -11
  36. package/bundled/core/test-driven-development.md +22 -978
  37. package/bundled/core/testing-standards.md +222 -2903
  38. package/bundled/core/versioning.md +16 -55
  39. package/bundled/core/virtual-organization-standards.md +85 -0
  40. package/bundled/locales/README.md +4 -4
  41. package/bundled/locales/zh-CN/CHANGELOG.md +18 -18
  42. package/bundled/locales/zh-CN/CLAUDE.md +3 -3
  43. package/bundled/locales/zh-CN/MAINTENANCE.md +7 -7
  44. package/bundled/locales/zh-CN/README.md +2 -2
  45. package/bundled/locales/zh-CN/STANDARDS-MAPPING.md +1 -1
  46. package/bundled/locales/zh-CN/adoption/ADOPTION-GUIDE.md +3 -3
  47. package/bundled/locales/zh-CN/adoption/DAILY-WORKFLOW-GUIDE.md +66 -7
  48. package/bundled/locales/zh-CN/adoption/STATIC-DYNAMIC-GUIDE.md +22 -22
  49. package/bundled/locales/zh-CN/adoption/checklists/enterprise.md +5 -5
  50. package/bundled/locales/zh-CN/adoption/checklists/minimal.md +4 -4
  51. package/bundled/locales/zh-CN/adoption/checklists/recommended.md +5 -5
  52. package/bundled/locales/zh-CN/ai/MAINTENANCE.md +13 -13
  53. package/bundled/locales/zh-CN/core/ai-instruction-standards.md +1 -1
  54. package/bundled/locales/zh-CN/core/anti-hallucination.md +39 -3
  55. package/bundled/locales/zh-CN/core/checkin-standards.md +18 -5
  56. package/bundled/locales/zh-CN/core/commit-message-guide.md +1 -1
  57. package/bundled/locales/zh-CN/core/developer-memory.md +576 -0
  58. package/bundled/locales/zh-CN/core/documentation-structure.md +43 -5
  59. package/bundled/locales/zh-CN/core/documentation-writing-standards.md +146 -5
  60. package/bundled/locales/zh-CN/core/git-workflow.md +179 -4
  61. package/bundled/locales/zh-CN/core/logging-standards.md +177 -4
  62. package/bundled/locales/zh-CN/core/project-structure.md +117 -5
  63. package/bundled/locales/zh-CN/core/refactoring-standards.md +3 -3
  64. package/bundled/locales/zh-CN/core/reverse-engineering-standards.md +6 -6
  65. package/bundled/locales/zh-CN/core/spec-driven-development.md +516 -14
  66. package/bundled/locales/zh-CN/core/test-completeness-dimensions.md +155 -24
  67. package/bundled/locales/zh-CN/core/test-driven-development.md +71 -20
  68. package/bundled/locales/zh-CN/core/testing-standards.md +4 -4
  69. package/bundled/locales/zh-CN/core/versioning.md +1 -1
  70. package/bundled/locales/zh-CN/docs/AI-AGENT-ROADMAP.md +90 -51
  71. package/bundled/locales/zh-CN/docs/CHEATSHEET.md +184 -0
  72. package/bundled/locales/zh-CN/docs/CLI-FLOW.md +239 -0
  73. package/bundled/locales/zh-CN/docs/FEATURE-REFERENCE.md +320 -0
  74. package/bundled/locales/zh-CN/docs/OPERATION-WORKFLOW.md +43 -43
  75. package/bundled/locales/zh-CN/docs/STANDARDS-REFERENCE.md +440 -0
  76. package/bundled/locales/zh-CN/docs/USAGE-MODES-COMPARISON.md +1 -1
  77. package/bundled/locales/zh-CN/docs/WINDOWS-GUIDE.md +1 -1
  78. package/bundled/locales/zh-CN/integrations/codex/README.md +3 -3
  79. package/bundled/locales/zh-CN/integrations/gemini-cli/README.md +3 -3
  80. package/bundled/locales/zh-CN/integrations/github-copilot/README.md +5 -5
  81. package/bundled/locales/zh-CN/integrations/github-copilot/copilot-instructions.md +9 -9
  82. package/bundled/locales/zh-CN/integrations/github-copilot/skills-mapping.md +18 -6
  83. package/bundled/locales/zh-CN/integrations/google-antigravity/README.md +2 -2
  84. package/bundled/locales/zh-CN/integrations/opencode/README.md +3 -3
  85. package/bundled/locales/zh-CN/integrations/opencode/skills-mapping.md +22 -10
  86. package/bundled/locales/zh-CN/integrations/openspec/README.md +1 -1
  87. package/bundled/locales/zh-CN/integrations/spec-kit/AGENTS.md +3 -3
  88. package/bundled/locales/zh-CN/integrations/spec-kit/README.md +1 -1
  89. package/bundled/locales/zh-CN/options/commit-message/bilingual.md +1 -1
  90. package/bundled/locales/zh-CN/options/commit-message/english.md +1 -1
  91. package/bundled/locales/zh-CN/options/commit-message/traditional-chinese.md +1 -1
  92. package/bundled/locales/zh-CN/options/git-workflow/gitflow.md +1 -1
  93. package/bundled/locales/zh-CN/options/git-workflow/github-flow.md +1 -1
  94. package/bundled/locales/zh-CN/options/git-workflow/merge-commit.md +1 -1
  95. package/bundled/locales/zh-CN/options/git-workflow/rebase-ff.md +1 -1
  96. package/bundled/locales/zh-CN/options/git-workflow/squash-merge.md +1 -1
  97. package/bundled/locales/zh-CN/options/git-workflow/trunk-based.md +1 -1
  98. package/bundled/locales/zh-CN/options/project-structure/dotnet.md +1 -1
  99. package/bundled/locales/zh-CN/options/project-structure/go.md +1 -1
  100. package/bundled/locales/zh-CN/options/project-structure/java.md +1 -1
  101. package/bundled/locales/zh-CN/options/project-structure/nodejs.md +1 -1
  102. package/bundled/locales/zh-CN/options/project-structure/python.md +1 -1
  103. package/bundled/locales/zh-CN/options/testing/e2e-testing.md +1 -1
  104. package/bundled/locales/zh-CN/options/testing/integration-testing.md +1 -1
  105. package/bundled/locales/zh-CN/options/testing/system-testing.md +1 -1
  106. package/bundled/locales/zh-CN/options/testing/unit-testing.md +1 -1
  107. package/bundled/locales/zh-CN/skills/{claude-code/CONTRIBUTING.template.md → CONTRIBUTING.template.md} +2 -2
  108. package/bundled/locales/zh-CN/skills/README.md +131 -81
  109. package/bundled/locales/zh-CN/skills/agents/README.md +281 -0
  110. package/bundled/locales/zh-CN/skills/{claude-code/ai-collaboration-standards → ai-collaboration-standards}/SKILL.md +10 -10
  111. package/bundled/locales/zh-CN/skills/{claude-code/ai-collaboration-standards → ai-collaboration-standards}/anti-hallucination.md +8 -8
  112. package/bundled/locales/zh-CN/skills/{claude-code/ai-collaboration-standards → ai-collaboration-standards}/certainty-labels.md +8 -8
  113. package/bundled/locales/zh-CN/skills/ai-friendly-architecture/SKILL.md +221 -0
  114. package/bundled/locales/zh-CN/skills/ai-instruction-standards/SKILL.md +214 -0
  115. package/bundled/locales/zh-CN/skills/atdd-assistant/SKILL.md +71 -0
  116. package/bundled/locales/zh-CN/skills/atdd-assistant/acceptance-criteria-guide.md +428 -0
  117. package/bundled/locales/zh-CN/skills/atdd-assistant/atdd-workflow.md +484 -0
  118. package/bundled/locales/zh-CN/skills/atdd-assistant/guide.md +368 -0
  119. package/bundled/locales/zh-CN/skills/bdd-assistant/SKILL.md +68 -0
  120. package/bundled/locales/zh-CN/skills/bdd-assistant/bdd-workflow.md +406 -0
  121. package/bundled/locales/zh-CN/skills/bdd-assistant/gherkin-guide.md +454 -0
  122. package/bundled/locales/zh-CN/skills/bdd-assistant/guide.md +324 -0
  123. package/bundled/locales/zh-CN/skills/changelog-guide/SKILL.md +64 -0
  124. package/bundled/locales/zh-CN/skills/{claude-code/changelog-guide/SKILL.md → changelog-guide/guide.md} +6 -7
  125. package/bundled/locales/zh-CN/skills/checkin-assistant/SKILL.md +56 -0
  126. package/bundled/locales/zh-CN/skills/{claude-code/checkin-assistant/SKILL.md → checkin-assistant/guide.md} +6 -7
  127. package/bundled/locales/zh-CN/skills/code-review-assistant/SKILL.md +56 -0
  128. package/bundled/locales/zh-CN/skills/{claude-code/code-review-assistant → code-review-assistant}/checkin-checklist.md +4 -4
  129. package/bundled/locales/zh-CN/skills/{claude-code/code-review-assistant/SKILL.md → code-review-assistant/guide.md} +5 -6
  130. package/bundled/locales/zh-CN/skills/{claude-code/code-review-assistant → code-review-assistant}/review-checklist.md +4 -4
  131. package/bundled/locales/zh-CN/skills/{claude-code/commands → commands}/bdd.md +2 -2
  132. package/bundled/locales/zh-CN/skills/{claude-code/commands → commands}/methodology.md +3 -3
  133. package/bundled/locales/zh-CN/skills/{claude-code/commands → commands}/refactor.md +3 -3
  134. package/bundled/locales/zh-CN/skills/commit-standards/SKILL.md +61 -0
  135. package/bundled/locales/zh-CN/skills/{claude-code/commit-standards → commit-standards}/conventional-commits.md +4 -4
  136. package/bundled/locales/zh-CN/skills/{claude-code/commit-standards/SKILL.md → commit-standards/guide.md} +5 -6
  137. package/bundled/locales/zh-CN/skills/{claude-code/commit-standards → commit-standards}/language-options.md +3 -3
  138. package/bundled/locales/zh-CN/skills/docs-generator/SKILL.md +59 -0
  139. package/bundled/locales/zh-CN/skills/docs-generator/guide.md +262 -0
  140. package/bundled/locales/zh-CN/skills/{claude-code/documentation-guide → documentation-guide}/SKILL.md +7 -8
  141. package/bundled/locales/zh-CN/skills/{claude-code/documentation-guide → documentation-guide}/documentation-structure.md +4 -4
  142. package/bundled/locales/zh-CN/skills/{claude-code/documentation-guide → documentation-guide}/readme-template.md +3 -3
  143. package/bundled/locales/zh-CN/skills/{claude-code/error-code-guide → error-code-guide}/SKILL.md +6 -6
  144. package/bundled/locales/zh-CN/skills/forward-derivation/SKILL.md +62 -0
  145. package/bundled/locales/zh-CN/skills/forward-derivation/guide.md +130 -0
  146. package/bundled/locales/zh-CN/skills/{claude-code/git-workflow-guide → git-workflow-guide}/SKILL.md +6 -6
  147. package/bundled/locales/zh-CN/skills/{claude-code/git-workflow-guide → git-workflow-guide}/branch-naming.md +3 -3
  148. package/bundled/locales/zh-CN/skills/{claude-code/git-workflow-guide → git-workflow-guide}/git-workflow.md +4 -4
  149. package/bundled/locales/zh-CN/skills/{claude-code/logging-guide → logging-guide}/SKILL.md +6 -6
  150. package/bundled/locales/zh-CN/skills/methodology-system/SKILL.md +78 -0
  151. package/bundled/locales/zh-CN/skills/{claude-code/methodology-system → methodology-system}/create-methodology.md +2 -2
  152. package/bundled/locales/zh-CN/skills/{claude-code/methodology-system/SKILL.md → methodology-system/guide.md} +2 -2
  153. package/bundled/locales/zh-CN/skills/{claude-code/methodology-system → methodology-system}/runtime.md +3 -3
  154. package/bundled/locales/zh-CN/skills/project-discovery/SKILL.md +66 -0
  155. package/bundled/locales/zh-CN/skills/project-discovery/guide.md +371 -0
  156. package/bundled/locales/zh-CN/skills/{claude-code/project-structure-guide → project-structure-guide}/SKILL.md +4 -4
  157. package/bundled/locales/zh-CN/skills/{claude-code/project-structure-guide → project-structure-guide}/language-patterns.md +1 -1
  158. package/bundled/locales/zh-CN/skills/refactoring-assistant/SKILL.md +67 -0
  159. package/bundled/locales/zh-CN/skills/{claude-code/refactoring-assistant/SKILL.md → refactoring-assistant/guide.md} +7 -8
  160. package/bundled/locales/zh-CN/skills/release-standards/SKILL.md +64 -0
  161. package/bundled/locales/zh-CN/skills/{claude-code/release-standards → release-standards}/changelog-format.md +3 -3
  162. package/bundled/locales/zh-CN/skills/{claude-code/release-standards/SKILL.md → release-standards/guide.md} +5 -6
  163. package/bundled/locales/zh-CN/skills/{claude-code/release-standards → release-standards}/release-workflow.md +7 -7
  164. package/bundled/locales/zh-CN/skills/{claude-code/release-standards → release-standards}/semantic-versioning.md +3 -3
  165. package/bundled/locales/zh-CN/skills/requirement-assistant/SKILL.md +67 -0
  166. package/bundled/locales/zh-CN/skills/{claude-code/requirement-assistant/SKILL.md → requirement-assistant/guide.md} +4 -5
  167. package/bundled/locales/zh-CN/skills/{claude-code/requirement-assistant → requirement-assistant}/requirement-checklist.md +3 -3
  168. package/bundled/locales/zh-CN/skills/{claude-code/requirement-assistant → requirement-assistant}/requirement-writing.md +3 -3
  169. package/bundled/locales/zh-CN/skills/reverse-engineer/SKILL.md +67 -0
  170. package/bundled/locales/zh-CN/skills/{claude-code/reverse-engineer → reverse-engineer}/bdd-extraction.md +2 -2
  171. package/bundled/locales/zh-CN/skills/{claude-code/reverse-engineer/SKILL.md → reverse-engineer/guide.md} +17 -18
  172. package/bundled/locales/zh-CN/skills/{claude-code/reverse-engineer → reverse-engineer}/tdd-analysis.md +2 -2
  173. package/bundled/locales/zh-CN/skills/{claude-code/reverse-engineer → reverse-engineer}/workflow.md +3 -3
  174. package/bundled/locales/zh-CN/skills/spec-driven-dev/SKILL.md +75 -0
  175. package/bundled/locales/zh-CN/skills/{claude-code/spec-driven-dev/SKILL.md → spec-driven-dev/guide.md} +10 -11
  176. package/bundled/locales/zh-CN/skills/tdd-assistant/SKILL.md +66 -0
  177. package/bundled/locales/zh-CN/skills/{claude-code/tdd-assistant/SKILL.md → tdd-assistant/guide.md} +12 -16
  178. package/bundled/locales/zh-CN/skills/{claude-code/tdd-assistant → tdd-assistant}/language-examples.md +3 -3
  179. package/bundled/locales/zh-CN/skills/{claude-code/tdd-assistant → tdd-assistant}/tdd-workflow.md +3 -3
  180. package/bundled/locales/zh-CN/skills/test-coverage-assistant/SKILL.md +65 -0
  181. package/bundled/locales/zh-CN/skills/test-coverage-assistant/guide.md +284 -0
  182. package/bundled/locales/zh-CN/skills/{claude-code/testing-guide → testing-guide}/SKILL.md +8 -8
  183. package/bundled/locales/zh-CN/skills/{claude-code/testing-guide → testing-guide}/testing-pyramid.md +4 -4
  184. package/bundled/locales/zh-CN/skills/{cline → tools/cline}/README.md +1 -1
  185. package/bundled/locales/zh-CN/skills/{copilot → tools/copilot}/README.md +1 -1
  186. package/bundled/locales/zh-CN/skills/{copilot → tools/copilot}/copilot-instructions.md +1 -1
  187. package/bundled/locales/zh-CN/skills/{cursor → tools/cursor}/README.md +1 -1
  188. package/bundled/locales/zh-CN/skills/{windsurf → tools/windsurf}/README.md +1 -1
  189. package/bundled/locales/zh-TW/CHANGELOG.md +16 -16
  190. package/bundled/locales/zh-TW/CLAUDE.md +3 -3
  191. package/bundled/locales/zh-TW/MAINTENANCE.md +7 -7
  192. package/bundled/locales/zh-TW/README.md +13 -7
  193. package/bundled/locales/zh-TW/STANDARDS-MAPPING.md +1 -1
  194. package/bundled/locales/zh-TW/adoption/ADOPTION-GUIDE.md +4 -4
  195. package/bundled/locales/zh-TW/adoption/DAILY-WORKFLOW-GUIDE.md +66 -7
  196. package/bundled/locales/zh-TW/adoption/STATIC-DYNAMIC-GUIDE.md +22 -22
  197. package/bundled/locales/zh-TW/adoption/checklists/enterprise.md +5 -5
  198. package/bundled/locales/zh-TW/adoption/checklists/minimal.md +4 -4
  199. package/bundled/locales/zh-TW/adoption/checklists/recommended.md +5 -5
  200. package/bundled/locales/zh-TW/ai/MAINTENANCE.md +13 -13
  201. package/bundled/locales/zh-TW/ai/standards/anti-hallucination.ai.yaml +3 -2
  202. package/bundled/locales/zh-TW/ai/standards/git-workflow.ai.yaml +4 -3
  203. package/bundled/locales/zh-TW/ai/standards/spec-driven-development.ai.yaml +3 -3
  204. package/bundled/locales/zh-TW/ai/standards/testing.ai.yaml +1 -0
  205. package/bundled/locales/zh-TW/core/ai-instruction-standards.md +1 -1
  206. package/bundled/locales/zh-TW/core/anti-hallucination.md +38 -701
  207. package/bundled/locales/zh-TW/core/changelog-standards.md +1 -1
  208. package/bundled/locales/zh-TW/core/checkin-standards.md +18 -5
  209. package/bundled/locales/zh-TW/core/code-review-checklist.md +1 -1
  210. package/bundled/locales/zh-TW/core/commit-message-guide.md +1 -1
  211. package/bundled/locales/zh-TW/core/developer-memory.md +576 -0
  212. package/bundled/locales/zh-TW/core/documentation-structure.md +115 -22
  213. package/bundled/locales/zh-TW/core/documentation-writing-standards.md +126 -5
  214. package/bundled/locales/zh-TW/core/forward-derivation-standards.md +2 -2
  215. package/bundled/locales/zh-TW/core/git-workflow.md +38 -812
  216. package/bundled/locales/zh-TW/core/guides/anti-hallucination-guide.md +779 -0
  217. package/bundled/locales/zh-TW/core/guides/git-workflow-guide.md +1016 -0
  218. package/bundled/locales/zh-TW/core/guides/refactoring-guide.md +864 -0
  219. package/bundled/locales/zh-TW/core/guides/testing-guide.md +2280 -0
  220. package/bundled/locales/zh-TW/core/logging-standards.md +159 -4
  221. package/bundled/locales/zh-TW/core/project-structure.md +102 -9
  222. package/bundled/locales/zh-TW/core/refactoring-standards.md +37 -823
  223. package/bundled/locales/zh-TW/core/reverse-engineering-standards.md +6 -6
  224. package/bundled/locales/zh-TW/core/spec-driven-development.md +17 -268
  225. package/bundled/locales/zh-TW/core/test-completeness-dimensions.md +128 -14
  226. package/bundled/locales/zh-TW/core/test-driven-development.md +20 -983
  227. package/bundled/locales/zh-TW/core/testing-standards.md +120 -2105
  228. package/bundled/locales/zh-TW/core/versioning.md +13 -55
  229. package/bundled/locales/zh-TW/docs/AI-AGENT-ROADMAP.md +90 -51
  230. package/bundled/locales/zh-TW/docs/CHEATSHEET.md +184 -0
  231. package/bundled/locales/zh-TW/docs/CLI-FLOW.md +239 -0
  232. package/bundled/locales/zh-TW/docs/FEATURE-REFERENCE.md +320 -0
  233. package/bundled/locales/zh-TW/docs/MIGRATION-V5.md +71 -0
  234. package/bundled/locales/zh-TW/docs/OPERATION-WORKFLOW.md +42 -42
  235. package/bundled/locales/zh-TW/docs/STANDARDS-REFERENCE.md +440 -0
  236. package/bundled/locales/zh-TW/docs/USAGE-MODES-COMPARISON.md +1 -1
  237. package/bundled/locales/zh-TW/docs/WINDOWS-GUIDE.md +1 -1
  238. package/bundled/locales/zh-TW/integrations/claude-code/README.md +44 -0
  239. package/bundled/locales/zh-TW/integrations/github-copilot/copilot-instructions.md +3 -3
  240. package/bundled/locales/zh-TW/integrations/github-copilot/skills-mapping.md +18 -6
  241. package/bundled/locales/zh-TW/integrations/opencode/skills-mapping.md +22 -10
  242. package/bundled/locales/zh-TW/methodologies/guides/sdd-guide.md +338 -0
  243. package/bundled/locales/zh-TW/methodologies/guides/tdd-guide.md +1055 -0
  244. package/bundled/locales/zh-TW/options/commit-message/bilingual.md +1 -1
  245. package/bundled/locales/zh-TW/options/commit-message/english.md +1 -1
  246. package/bundled/locales/zh-TW/options/commit-message/traditional-chinese.md +1 -1
  247. package/bundled/locales/zh-TW/options/git-workflow/gitflow.md +1 -1
  248. package/bundled/locales/zh-TW/options/git-workflow/github-flow.md +1 -1
  249. package/bundled/locales/zh-TW/options/git-workflow/merge-commit.md +1 -1
  250. package/bundled/locales/zh-TW/options/git-workflow/rebase-ff.md +1 -1
  251. package/bundled/locales/zh-TW/options/git-workflow/squash-merge.md +1 -1
  252. package/bundled/locales/zh-TW/options/git-workflow/trunk-based.md +1 -1
  253. package/bundled/locales/zh-TW/options/project-structure/dotnet.md +1 -1
  254. package/bundled/locales/zh-TW/options/project-structure/go.md +1 -1
  255. package/bundled/locales/zh-TW/options/project-structure/java.md +1 -1
  256. package/bundled/locales/zh-TW/options/project-structure/nodejs.md +1 -1
  257. package/bundled/locales/zh-TW/options/project-structure/python.md +1 -1
  258. package/bundled/locales/zh-TW/options/testing/e2e-testing.md +1 -1
  259. package/bundled/locales/zh-TW/options/testing/integration-testing.md +1 -1
  260. package/bundled/locales/zh-TW/options/testing/system-testing.md +1 -1
  261. package/bundled/locales/zh-TW/options/testing/unit-testing.md +1 -1
  262. package/bundled/locales/zh-TW/skills/{claude-code/CONTRIBUTING.template.md → CONTRIBUTING.template.md} +2 -2
  263. package/bundled/locales/zh-TW/skills/README.md +131 -79
  264. package/bundled/locales/zh-TW/skills/agents/README.md +281 -0
  265. package/bundled/locales/zh-TW/skills/{claude-code/ai-collaboration-standards → ai-collaboration-standards}/SKILL.md +7 -7
  266. package/bundled/locales/zh-TW/skills/{claude-code/ai-collaboration-standards → ai-collaboration-standards}/anti-hallucination.md +8 -8
  267. package/bundled/locales/zh-TW/skills/{claude-code/ai-collaboration-standards → ai-collaboration-standards}/certainty-labels.md +8 -8
  268. package/bundled/locales/zh-TW/skills/ai-friendly-architecture/SKILL.md +221 -0
  269. package/bundled/locales/zh-TW/skills/ai-instruction-standards/SKILL.md +214 -0
  270. package/bundled/locales/zh-TW/skills/atdd-assistant/SKILL.md +71 -0
  271. package/bundled/locales/zh-TW/skills/atdd-assistant/acceptance-criteria-guide.md +428 -0
  272. package/bundled/locales/zh-TW/skills/atdd-assistant/atdd-workflow.md +484 -0
  273. package/bundled/locales/zh-TW/skills/atdd-assistant/guide.md +368 -0
  274. package/bundled/locales/zh-TW/skills/bdd-assistant/SKILL.md +68 -0
  275. package/bundled/locales/zh-TW/skills/bdd-assistant/bdd-workflow.md +406 -0
  276. package/bundled/locales/zh-TW/skills/bdd-assistant/gherkin-guide.md +454 -0
  277. package/bundled/locales/zh-TW/skills/bdd-assistant/guide.md +324 -0
  278. package/bundled/locales/zh-TW/skills/changelog-guide/SKILL.md +64 -0
  279. package/bundled/locales/zh-TW/skills/{claude-code/changelog-guide/SKILL.md → changelog-guide/guide.md} +6 -7
  280. package/bundled/locales/zh-TW/skills/checkin-assistant/SKILL.md +56 -0
  281. package/bundled/locales/zh-TW/skills/{claude-code/checkin-assistant/SKILL.md → checkin-assistant/guide.md} +6 -7
  282. package/bundled/locales/zh-TW/skills/code-review-assistant/SKILL.md +56 -0
  283. package/bundled/locales/zh-TW/skills/{claude-code/code-review-assistant → code-review-assistant}/checkin-checklist.md +4 -4
  284. package/bundled/locales/zh-TW/skills/{claude-code/code-review-assistant/SKILL.md → code-review-assistant/guide.md} +2 -3
  285. package/bundled/locales/zh-TW/skills/{claude-code/code-review-assistant → code-review-assistant}/review-checklist.md +4 -4
  286. package/bundled/locales/zh-TW/skills/{claude-code/commands → commands}/bdd.md +2 -2
  287. package/bundled/locales/zh-TW/skills/{claude-code/commands → commands}/methodology.md +3 -3
  288. package/bundled/locales/zh-TW/skills/{claude-code/commands → commands}/refactor.md +3 -3
  289. package/bundled/locales/zh-TW/skills/commit-standards/SKILL.md +61 -0
  290. package/bundled/locales/zh-TW/skills/{claude-code/commit-standards → commit-standards}/conventional-commits.md +4 -4
  291. package/bundled/locales/zh-TW/skills/{claude-code/commit-standards/SKILL.md → commit-standards/guide.md} +5 -6
  292. package/bundled/locales/zh-TW/skills/{claude-code/commit-standards → commit-standards}/language-options.md +3 -3
  293. package/bundled/locales/zh-TW/skills/docs-generator/SKILL.md +59 -0
  294. package/bundled/locales/zh-TW/skills/docs-generator/guide.md +262 -0
  295. package/bundled/locales/zh-TW/skills/{claude-code/documentation-guide → documentation-guide}/SKILL.md +7 -8
  296. package/bundled/locales/zh-TW/skills/{claude-code/documentation-guide → documentation-guide}/documentation-structure.md +4 -4
  297. package/bundled/locales/zh-TW/skills/{claude-code/documentation-guide → documentation-guide}/readme-template.md +3 -3
  298. package/bundled/locales/zh-TW/skills/{claude-code/error-code-guide → error-code-guide}/SKILL.md +6 -6
  299. package/bundled/locales/zh-TW/skills/forward-derivation/SKILL.md +62 -0
  300. package/bundled/locales/zh-TW/skills/{claude-code/forward-derivation/SKILL.md → forward-derivation/guide.md} +24 -19
  301. package/bundled/locales/zh-TW/skills/{claude-code/git-workflow-guide → git-workflow-guide}/SKILL.md +3 -3
  302. package/bundled/locales/zh-TW/skills/{claude-code/git-workflow-guide → git-workflow-guide}/branch-naming.md +3 -3
  303. package/bundled/locales/zh-TW/skills/{claude-code/git-workflow-guide → git-workflow-guide}/git-workflow.md +4 -4
  304. package/bundled/locales/zh-TW/skills/{claude-code/logging-guide → logging-guide}/SKILL.md +6 -6
  305. package/bundled/locales/zh-TW/skills/methodology-system/SKILL.md +78 -0
  306. package/bundled/locales/zh-TW/skills/{claude-code/methodology-system → methodology-system}/create-methodology.md +2 -2
  307. package/bundled/locales/zh-TW/skills/{claude-code/methodology-system/SKILL.md → methodology-system/guide.md} +2 -2
  308. package/bundled/locales/zh-TW/skills/{claude-code/methodology-system → methodology-system}/runtime.md +3 -3
  309. package/bundled/locales/zh-TW/skills/project-discovery/SKILL.md +66 -0
  310. package/bundled/locales/zh-TW/skills/project-discovery/guide.md +371 -0
  311. package/bundled/locales/zh-TW/skills/project-discovery/workflow.md +574 -0
  312. package/bundled/locales/zh-TW/skills/{claude-code/project-structure-guide → project-structure-guide}/SKILL.md +4 -4
  313. package/bundled/locales/zh-TW/skills/{claude-code/project-structure-guide → project-structure-guide}/language-patterns.md +1 -1
  314. package/bundled/locales/zh-TW/skills/refactoring-assistant/SKILL.md +67 -0
  315. package/bundled/locales/zh-TW/skills/{claude-code/refactoring-assistant/SKILL.md → refactoring-assistant/guide.md} +7 -8
  316. package/bundled/locales/zh-TW/skills/release-standards/SKILL.md +64 -0
  317. package/bundled/locales/zh-TW/skills/{claude-code/release-standards → release-standards}/changelog-format.md +3 -3
  318. package/bundled/locales/zh-TW/skills/{claude-code/release-standards/SKILL.md → release-standards/guide.md} +2 -3
  319. package/bundled/locales/zh-TW/skills/{claude-code/release-standards → release-standards}/release-workflow.md +60 -28
  320. package/bundled/locales/zh-TW/skills/{claude-code/release-standards → release-standards}/semantic-versioning.md +3 -3
  321. package/bundled/locales/zh-TW/skills/requirement-assistant/SKILL.md +67 -0
  322. package/bundled/locales/zh-TW/skills/{claude-code/requirement-assistant/SKILL.md → requirement-assistant/guide.md} +2 -3
  323. package/bundled/locales/zh-TW/skills/{claude-code/requirement-assistant → requirement-assistant}/requirement-checklist.md +3 -3
  324. package/bundled/locales/zh-TW/skills/{claude-code/requirement-assistant → requirement-assistant}/requirement-writing.md +3 -3
  325. package/bundled/locales/zh-TW/skills/reverse-engineer/SKILL.md +67 -0
  326. package/bundled/locales/zh-TW/skills/{claude-code/reverse-engineer → reverse-engineer}/bdd-extraction.md +2 -2
  327. package/bundled/locales/zh-TW/skills/{claude-code/reverse-engineer/SKILL.md → reverse-engineer/guide.md} +17 -18
  328. package/bundled/locales/zh-TW/skills/{claude-code/reverse-engineer → reverse-engineer}/tdd-analysis.md +2 -2
  329. package/bundled/locales/zh-TW/skills/{claude-code/reverse-engineer → reverse-engineer}/workflow.md +3 -3
  330. package/bundled/locales/zh-TW/skills/spec-driven-dev/SKILL.md +75 -0
  331. package/bundled/locales/zh-TW/skills/{claude-code/spec-driven-dev/SKILL.md → spec-driven-dev/guide.md} +9 -10
  332. package/bundled/locales/zh-TW/skills/tdd-assistant/SKILL.md +66 -0
  333. package/bundled/locales/zh-TW/skills/{claude-code/tdd-assistant/SKILL.md → tdd-assistant/guide.md} +9 -10
  334. package/bundled/locales/zh-TW/skills/{claude-code/tdd-assistant → tdd-assistant}/language-examples.md +3 -3
  335. package/bundled/locales/zh-TW/skills/{claude-code/tdd-assistant → tdd-assistant}/tdd-workflow.md +3 -3
  336. package/bundled/locales/zh-TW/skills/test-coverage-assistant/SKILL.md +65 -0
  337. package/bundled/locales/zh-TW/skills/{claude-code/test-coverage-assistant/SKILL.md → test-coverage-assistant/guide.md} +27 -24
  338. package/bundled/locales/zh-TW/skills/{claude-code/testing-guide → testing-guide}/SKILL.md +6 -6
  339. package/bundled/locales/zh-TW/skills/{claude-code/testing-guide → testing-guide}/testing-pyramid.md +4 -4
  340. package/bundled/locales/zh-TW/skills/{cline → tools/cline}/README.md +1 -1
  341. package/bundled/locales/zh-TW/skills/{copilot → tools/copilot}/README.md +1 -1
  342. package/bundled/locales/zh-TW/skills/{copilot → tools/copilot}/copilot-instructions.md +1 -1
  343. package/bundled/locales/zh-TW/skills/{cursor → tools/cursor}/README.md +1 -1
  344. package/bundled/locales/zh-TW/skills/{windsurf → tools/windsurf}/README.md +1 -1
  345. package/bundled/skills/INTEGRATION-GUIDE.md +210 -0
  346. package/bundled/skills/README.md +95 -0
  347. package/bundled/skills/_shared/README.md +60 -0
  348. package/bundled/skills/{claude-code/agents → agents}/README.md +2 -2
  349. package/bundled/skills/{claude-code/agents → agents}/code-architect.md +1 -1
  350. package/bundled/skills/{claude-code/agents → agents}/doc-writer.md +1 -1
  351. package/bundled/skills/{claude-code/agents → agents}/reviewer.md +1 -1
  352. package/bundled/skills/{claude-code/agents → agents}/spec-analyst.md +1 -1
  353. package/bundled/skills/{claude-code/agents → agents}/test-specialist.md +1 -1
  354. package/bundled/skills/{claude-code/ai-collaboration-standards → ai-collaboration-standards}/SKILL.md +28 -5
  355. package/bundled/skills/{claude-code/ai-collaboration-standards → ai-collaboration-standards}/anti-hallucination.md +24 -5
  356. package/bundled/skills/{claude-code/ai-collaboration-standards → ai-collaboration-standards}/certainty-labels.md +31 -6
  357. package/bundled/skills/ai-friendly-architecture/SKILL.md +216 -0
  358. package/bundled/skills/ai-instruction-standards/SKILL.md +209 -0
  359. package/bundled/skills/atdd-assistant/SKILL.md +74 -0
  360. package/bundled/skills/{claude-code/atdd-assistant → atdd-assistant}/acceptance-criteria-guide.md +1 -1
  361. package/bundled/skills/{claude-code/atdd-assistant → atdd-assistant}/atdd-workflow.md +1 -1
  362. package/bundled/skills/{claude-code/atdd-assistant/SKILL.md → atdd-assistant/guide.md} +11 -11
  363. package/bundled/skills/bdd-assistant/SKILL.md +70 -0
  364. package/bundled/skills/{claude-code/bdd-assistant → bdd-assistant}/bdd-workflow.md +1 -1
  365. package/bundled/skills/{claude-code/bdd-assistant → bdd-assistant}/gherkin-guide.md +1 -1
  366. package/bundled/skills/{claude-code/bdd-assistant/SKILL.md → bdd-assistant/guide.md} +11 -11
  367. package/bundled/skills/changelog-guide/SKILL.md +66 -0
  368. package/bundled/skills/{claude-code/changelog-guide/SKILL.md → changelog-guide/guide.md} +8 -6
  369. package/bundled/skills/checkin-assistant/SKILL.md +52 -0
  370. package/bundled/skills/{claude-code/checkin-assistant/SKILL.md → checkin-assistant/guide.md} +6 -6
  371. package/bundled/skills/code-review-assistant/SKILL.md +53 -0
  372. package/bundled/skills/{claude-code/code-review-assistant → code-review-assistant}/checkin-checklist.md +3 -3
  373. package/bundled/skills/{claude-code/code-review-assistant/SKILL.md → code-review-assistant/guide.md} +7 -5
  374. package/bundled/skills/{claude-code/code-review-assistant → code-review-assistant}/review-checklist.md +3 -3
  375. package/bundled/skills/commands/COMMAND-FAMILY-OVERVIEW.md +290 -0
  376. package/bundled/skills/{claude-code/commands → commands}/README.md +13 -3
  377. package/bundled/skills/{claude-code/commands → commands}/atdd.md +3 -3
  378. package/bundled/skills/{claude-code/commands → commands}/bdd.md +2 -2
  379. package/bundled/skills/commands/changelog.md +58 -0
  380. package/bundled/skills/{claude-code/commands → commands}/check.md +1 -1
  381. package/bundled/skills/commands/checkin.md +53 -0
  382. package/bundled/skills/{claude-code/commands → commands}/commit.md +3 -3
  383. package/bundled/skills/{claude-code/commands → commands}/config.md +1 -1
  384. package/bundled/skills/{claude-code/commands → commands}/coverage.md +5 -4
  385. package/bundled/skills/commands/derive-all.md +53 -0
  386. package/bundled/skills/commands/derive-atdd.md +49 -0
  387. package/bundled/skills/commands/derive-bdd.md +47 -0
  388. package/bundled/skills/commands/derive-tdd.md +48 -0
  389. package/bundled/skills/commands/derive.md +72 -0
  390. package/bundled/skills/commands/discover.md +80 -0
  391. package/bundled/skills/commands/docgen.md +61 -0
  392. package/bundled/skills/commands/docs.md +59 -0
  393. package/bundled/skills/commands/guide.md +44 -0
  394. package/bundled/skills/{claude-code/commands → commands}/init.md +2 -2
  395. package/bundled/skills/{claude-code/commands → commands}/methodology.md +32 -16
  396. package/bundled/skills/{claude-code/commands → commands}/refactor.md +2 -2
  397. package/bundled/skills/commands/release.md +56 -0
  398. package/bundled/skills/{claude-code/commands → commands}/requirement.md +3 -3
  399. package/bundled/skills/commands/reverse-bdd.md +47 -0
  400. package/bundled/skills/commands/reverse-sdd.md +51 -0
  401. package/bundled/skills/commands/reverse-tdd.md +51 -0
  402. package/bundled/skills/commands/reverse.md +63 -0
  403. package/bundled/skills/{claude-code/commands → commands}/review.md +3 -3
  404. package/bundled/skills/commands/sdd.md +135 -0
  405. package/bundled/skills/{claude-code/commands → commands}/tdd.md +3 -3
  406. package/bundled/skills/{claude-code/commands → commands}/update.md +2 -2
  407. package/bundled/skills/commit-standards/SKILL.md +60 -0
  408. package/bundled/skills/{claude-code/commit-standards → commit-standards}/conventional-commits.md +3 -3
  409. package/bundled/skills/{claude-code/commit-standards/SKILL.md → commit-standards/guide.md} +17 -5
  410. package/bundled/skills/{claude-code/commit-standards → commit-standards}/language-options.md +2 -2
  411. package/bundled/skills/docs-generator/SKILL.md +69 -0
  412. package/bundled/skills/docs-generator/guide.md +258 -0
  413. package/bundled/skills/{claude-code/documentation-guide → documentation-guide}/SKILL.md +7 -7
  414. package/bundled/skills/{claude-code/documentation-guide → documentation-guide}/documentation-structure.md +3 -3
  415. package/bundled/skills/{claude-code/documentation-guide → documentation-guide}/readme-template.md +2 -2
  416. package/bundled/skills/{claude-code/error-code-guide → error-code-guide}/SKILL.md +7 -5
  417. package/bundled/skills/forward-derivation/SKILL.md +61 -0
  418. package/bundled/skills/{claude-code/forward-derivation/SKILL.md → forward-derivation/guide.md} +44 -29
  419. package/bundled/skills/{claude-code/git-workflow-guide → git-workflow-guide}/SKILL.md +7 -5
  420. package/bundled/skills/{claude-code/git-workflow-guide → git-workflow-guide}/branch-naming.md +2 -2
  421. package/bundled/skills/{claude-code/git-workflow-guide → git-workflow-guide}/git-workflow.md +3 -3
  422. package/bundled/skills/{claude-code/logging-guide → logging-guide}/SKILL.md +7 -5
  423. package/bundled/skills/methodology-system/SKILL.md +75 -0
  424. package/bundled/skills/{claude-code/methodology-system → methodology-system}/create-methodology.md +1 -1
  425. package/bundled/skills/{claude-code/methodology-system/SKILL.md → methodology-system/guide.md} +51 -16
  426. package/bundled/skills/methodology-system/integrated-flow.md +454 -0
  427. package/bundled/skills/{claude-code/methodology-system → methodology-system}/runtime.md +2 -2
  428. package/bundled/skills/project-discovery/SKILL.md +63 -0
  429. package/bundled/skills/project-discovery/guide.md +367 -0
  430. package/bundled/skills/project-discovery/workflow.md +566 -0
  431. package/bundled/skills/{claude-code/project-structure-guide → project-structure-guide}/SKILL.md +14 -4
  432. package/bundled/skills/refactoring-assistant/SKILL.md +78 -0
  433. package/bundled/skills/{claude-code/refactoring-assistant/SKILL.md → refactoring-assistant/guide.md} +7 -7
  434. package/bundled/skills/release-standards/SKILL.md +61 -0
  435. package/bundled/skills/{claude-code/release-standards → release-standards}/changelog-format.md +2 -2
  436. package/bundled/skills/{claude-code/release-standards/SKILL.md → release-standards/guide.md} +7 -5
  437. package/bundled/skills/{claude-code/release-standards → release-standards}/release-workflow.md +59 -24
  438. package/bundled/skills/{claude-code/release-standards → release-standards}/semantic-versioning.md +2 -2
  439. package/bundled/skills/requirement-assistant/SKILL.md +66 -0
  440. package/bundled/skills/{claude-code/requirement-assistant/SKILL.md → requirement-assistant/guide.md} +14 -6
  441. package/bundled/skills/{claude-code/requirement-assistant → requirement-assistant}/requirement-checklist.md +2 -2
  442. package/bundled/skills/{claude-code/requirement-assistant → requirement-assistant}/requirement-writing.md +2 -2
  443. package/bundled/skills/reverse-engineer/SKILL.md +64 -0
  444. package/bundled/skills/{claude-code/reverse-engineer → reverse-engineer}/bdd-extraction.md +1 -1
  445. package/bundled/skills/{claude-code/reverse-engineer/SKILL.md → reverse-engineer/guide.md} +21 -18
  446. package/bundled/skills/{claude-code/reverse-engineer → reverse-engineer}/tdd-analysis.md +1 -1
  447. package/bundled/skills/{claude-code/reverse-engineer → reverse-engineer}/workflow.md +2 -2
  448. package/bundled/skills/spec-driven-dev/SKILL.md +80 -0
  449. package/bundled/skills/{claude-code/spec-driven-dev/SKILL.md → spec-driven-dev/guide.md} +50 -8
  450. package/bundled/skills/tdd-assistant/SKILL.md +65 -0
  451. package/bundled/skills/{claude-code/tdd-assistant/SKILL.md → tdd-assistant/guide.md} +10 -10
  452. package/bundled/skills/{claude-code/tdd-assistant → tdd-assistant}/language-examples.md +3 -3
  453. package/bundled/skills/{claude-code/tdd-assistant → tdd-assistant}/tdd-workflow.md +2 -2
  454. package/bundled/skills/test-coverage-assistant/SKILL.md +63 -0
  455. package/bundled/skills/{claude-code/test-coverage-assistant/SKILL.md → test-coverage-assistant/guide.md} +39 -24
  456. package/bundled/skills/{claude-code/testing-guide → testing-guide}/SKILL.md +12 -7
  457. package/bundled/skills/{claude-code/testing-guide → testing-guide}/testing-pyramid.md +3 -3
  458. package/bundled/skills/testing-guide/testing-theory.md +2291 -0
  459. package/bundled/skills/tools/cline/.clinerules +79 -0
  460. package/bundled/skills/tools/cline/README.md +50 -0
  461. package/bundled/skills/tools/copilot/README.md +99 -0
  462. package/bundled/skills/tools/copilot/copilot-instructions.md +71 -0
  463. package/bundled/skills/tools/cursor/.cursorrules +101 -0
  464. package/bundled/skills/tools/cursor/README.md +50 -0
  465. package/bundled/skills/tools/windsurf/.windsurfrules +76 -0
  466. package/bundled/skills/tools/windsurf/README.md +51 -0
  467. package/bundled/skills/{claude-code/workflows → workflows}/README.md +1 -1
  468. package/bundled/skills/workflows/release.workflow.yaml +893 -0
  469. package/package.json +4 -1
  470. package/src/commands/check.js +195 -130
  471. package/src/commands/config.js +1262 -0
  472. package/src/commands/configure.js +3 -950
  473. package/src/commands/fix.js +53 -0
  474. package/src/commands/hitl.js +19 -0
  475. package/src/commands/init.js +320 -1030
  476. package/src/commands/list.js +1 -1
  477. package/src/commands/simulate.js +61 -0
  478. package/src/commands/spec.js +288 -0
  479. package/src/commands/start.js +373 -0
  480. package/src/commands/sweep.js +142 -0
  481. package/src/commands/update.js +136 -19
  482. package/src/commands/workflow.js +265 -1
  483. package/src/config/ai-agent-paths.js +89 -29
  484. package/src/core/constants.js +7 -1
  485. package/src/core/manifest.js +1 -0
  486. package/src/flows/init-flow.js +243 -0
  487. package/src/hitl/checkpoint.js +80 -0
  488. package/src/hitl/classifier.js +54 -0
  489. package/src/hitl/manager.js +88 -0
  490. package/src/i18n/messages.js +907 -99
  491. package/src/index.js +1 -0
  492. package/src/installers/integration-installer.js +237 -0
  493. package/src/installers/manifest-installer.js +131 -0
  494. package/src/installers/skills-installer.js +286 -0
  495. package/src/installers/standards-installer.js +193 -0
  496. package/src/missions/MissionManager.js +501 -0
  497. package/src/prompts/init.js +228 -130
  498. package/src/prompts/integrations.js +13 -1
  499. package/src/schemas/standard.schema.json +117 -0
  500. package/src/utils/agents-installer.js +2 -2
  501. package/src/utils/config-loader.js +47 -0
  502. package/src/utils/config-manager.js +108 -0
  503. package/src/utils/config-merger.js +47 -0
  504. package/src/utils/github.js +22 -18
  505. package/src/utils/inquirer-patch.js +98 -0
  506. package/src/utils/integration-generator.js +392 -58
  507. package/src/utils/reference-sync.js +69 -19
  508. package/src/utils/skills-installer.js +6 -3
  509. package/src/utils/standard-fixer.js +141 -0
  510. package/src/utils/standard-validator.js +329 -0
  511. package/src/utils/workflow-executor.js +886 -0
  512. package/src/utils/workflow-state.js +404 -0
  513. package/src/utils/workflows-installer.js +2 -2
  514. package/src/vibe/auto-sweep.js +349 -0
  515. package/src/vibe/micro-spec.js +428 -0
  516. package/standards-registry.json +278 -102
  517. package/bundled/locales/zh-CN/skills/claude-code/README.md +0 -174
  518. package/bundled/locales/zh-CN/skills/claude-code/test-coverage-assistant/SKILL.md +0 -282
  519. package/bundled/locales/zh-TW/skills/claude-code/README.md +0 -174
  520. package/bundled/skills/claude-code/README.md +0 -215
  521. package/bundled/skills/claude-code/commands/changelog.md +0 -57
  522. package/bundled/skills/claude-code/commands/derive-all.md +0 -214
  523. package/bundled/skills/claude-code/commands/derive-atdd.md +0 -177
  524. package/bundled/skills/claude-code/commands/derive-bdd.md +0 -158
  525. package/bundled/skills/claude-code/commands/derive-tdd.md +0 -259
  526. package/bundled/skills/claude-code/commands/docs.md +0 -75
  527. package/bundled/skills/claude-code/commands/release.md +0 -50
  528. package/bundled/skills/claude-code/commands/reverse-bdd.md +0 -264
  529. package/bundled/skills/claude-code/commands/reverse-spec.md +0 -185
  530. package/bundled/skills/claude-code/commands/reverse-tdd.md +0 -351
  531. package/bundled/skills/claude-code/commands/spec.md +0 -69
  532. package/bundled/skills/claude-code/methodology-system/integrated-flow.md +0 -322
  533. /package/bundled/skills/{claude-code/CONTRIBUTING.template.md → CONTRIBUTING.template.md} +0 -0
  534. /package/bundled/skills/{claude-code/ai → ai}/standards/checkin.ai.yaml +0 -0
  535. /package/bundled/skills/{claude-code/ai → ai}/standards/commit.ai.yaml +0 -0
  536. /package/bundled/skills/{claude-code/ai → ai}/standards/refactoring.ai.yaml +0 -0
  537. /package/bundled/skills/{claude-code/ai → ai}/standards/testing.ai.yaml +0 -0
  538. /package/bundled/skills/{claude-code/project-structure-guide → project-structure-guide}/language-patterns.md +0 -0
  539. /package/bundled/skills/{claude-code/workflows → workflows}/code-review.workflow.yaml +0 -0
  540. /package/bundled/skills/{claude-code/workflows → workflows}/feature-dev.workflow.yaml +0 -0
  541. /package/bundled/skills/{claude-code/workflows → workflows}/integrated-flow.workflow.yaml +0 -0
  542. /package/bundled/skills/{claude-code/workflows → workflows}/large-codebase-analysis.workflow.yaml +0 -0
@@ -0,0 +1,2291 @@
1
+ # Testing Theory Knowledge Base
2
+
3
+ > **Language**: English | [繁體中文](../../locales/zh-TW/skills/testing-guide/testing-theory.md)
4
+
5
+ **Version**: 1.0.0
6
+ **Last Updated**: 2026-01-29
7
+ **Applicability**: Educational reference for testers and developers
8
+ **Scope**: universal
9
+
10
+ ---
11
+
12
+ ## Purpose
13
+
14
+ This document provides the theoretical foundations, educational content, and detailed examples for software testing. It serves as a comprehensive knowledge base to support the actionable rules defined in [Testing Standards](../../core/testing-standards.md).
15
+
16
+ **Reference Standards**:
17
+ - [ISTQB CTFL v4.0](https://istqb.org/certifications/certified-tester-foundation-level-ctfl-v4-0/)
18
+ - [ISO/IEC/IEEE 29119](https://www.iso.org/standard/81291.html)
19
+ - [SWEBOK v4.0](https://www.computer.org/education/bodies-of-knowledge/software-engineering) - IEEE Computer Society
20
+
21
+ ---
22
+
23
+ ## Table of Contents
24
+
25
+ 1. [Testing Fundamentals](#testing-fundamentals)
26
+ 2. [Static Testing](#static-testing)
27
+ 3. [Test Design Techniques](#test-design-techniques)
28
+ 4. [Experience-Based Testing](#experience-based-testing)
29
+ 5. [Risk-Based Testing](#risk-based-testing)
30
+ 6. [Specialized Testing](#specialized-testing)
31
+ 7. [Test-Related Measures](#test-related-measures)
32
+ 8. [Defect Management](#defect-management)
33
+ 9. [Test Process Management](#test-process-management)
34
+ 10. [Code Examples by Test Level](#code-examples-by-test-level)
35
+ 11. [Quick Reference Card](#quick-reference-card)
36
+
37
+ ---
38
+
39
+ ## Testing Fundamentals
40
+
41
+ Understanding the theoretical foundations of software testing is essential for effective test design and execution.
42
+
43
+ **Reference**: SWEBOK v4.0 Chapter 5
44
+
45
+ ### Faults vs Failures
46
+
47
+ ```
48
+ ┌─────────────────────────────────────────────────────────────┐
49
+ │ Faults, Errors, and Failures │
50
+ ├─────────────────────────────────────────────────────────────┤
51
+ │ │
52
+ │ Error (Mistake) │
53
+ │ │ │
54
+ │ ▼ introduced during development │
55
+ │ ┌─────────┐ │
56
+ │ │ Fault │ (Defect/Bug in the code) │
57
+ │ └─────────┘ │
58
+ │ │ │
59
+ │ ▼ when executed │
60
+ │ ┌─────────┐ │
61
+ │ │ Failure │ (Observable incorrect behavior) │
62
+ │ └─────────┘ │
63
+ │ │
64
+ │ Key Points: │
65
+ │ • A fault may exist without causing a failure │
66
+ │ • A failure requires a fault to be executed │
67
+ │ • Multiple faults can cause the same failure │
68
+ │ • Testing finds failures; debugging finds faults │
69
+ │ │
70
+ └─────────────────────────────────────────────────────────────┘
71
+ ```
72
+
73
+ ### The Oracle Problem
74
+
75
+ An **oracle** is any mechanism that determines whether observed program behavior is correct. The oracle problem addresses the challenge of knowing expected outcomes.
76
+
77
+ ```
78
+ ┌─────────────────────────────────────────────────────────────┐
79
+ │ Oracle Types │
80
+ ├─────────────────────────────────────────────────────────────┤
81
+ │ │
82
+ │ Human Oracle │
83
+ │ └── Manual verification by domain expert │
84
+ │ │
85
+ │ Specification-Based Oracle │
86
+ │ └── Compare against formal requirements │
87
+ │ │
88
+ │ Reference Implementation │
89
+ │ └── Compare against known-correct implementation │
90
+ │ │
91
+ │ Metamorphic Oracle │
92
+ │ └── Verify relationships between outputs │
93
+ │ (e.g., sort(sort(x)) == sort(x)) │
94
+ │ │
95
+ │ Statistical Oracle │
96
+ │ └── Validate against expected distributions │
97
+ │ │
98
+ │ Implicit Oracle │
99
+ │ └── No crash, no exception, no timeout │
100
+ │ │
101
+ └─────────────────────────────────────────────────────────────┘
102
+ ```
103
+
104
+ ### Theoretical Limitations of Testing
105
+
106
+ > "Program testing can be used to show the presence of bugs, but never to show their absence." — Edsger W. Dijkstra
107
+
108
+ ```
109
+ ┌─────────────────────────────────────────────────────────────┐
110
+ │ Testing Limitations │
111
+ ├─────────────────────────────────────────────────────────────┤
112
+ │ │
113
+ │ Exhaustive Testing is Impossible │
114
+ │ ├── Infinite input domain │
115
+ │ ├── State space explosion │
116
+ │ └── Timing and concurrency variations │
117
+ │ │
118
+ │ Infeasible Paths │
119
+ │ ├── Some code paths cannot be executed by any input │
120
+ │ ├── Dead code may appear reachable in CFG │
121
+ │ └── 100% path coverage may be mathematically impossible │
122
+ │ │
123
+ │ Halting Problem │
124
+ │ └── Cannot algorithmically determine if all tests halt │
125
+ │ │
126
+ │ Implications: │
127
+ │ • Testing is sampling, not proof │
128
+ │ • Risk-based prioritization is essential │
129
+ │ • Combine testing with formal methods where critical │
130
+ │ │
131
+ └─────────────────────────────────────────────────────────────┘
132
+ ```
133
+
134
+ ### Testability
135
+
136
+ Testability measures how easily software can be tested effectively.
137
+
138
+ | Factor | Description | How to Improve |
139
+ |--------|-------------|----------------|
140
+ | **Controllability** | Ability to set system state for testing | Provide test hooks, dependency injection |
141
+ | **Observability** | Ability to observe test results | Add logging, expose internal state |
142
+ | **Isolability** | Ability to test components independently | Modular design, clear interfaces |
143
+ | **Understandability** | Clarity of expected behavior | Good documentation, clear specifications |
144
+ | **Stability** | Low rate of change | Freeze features before testing phase |
145
+ | **Simplicity** | Low complexity | Reduce cyclomatic complexity |
146
+
147
+ ### Test Adequacy Criteria
148
+
149
+ Test adequacy criteria answer: "Have we tested enough?"
150
+
151
+ ```
152
+ ┌─────────────────────────────────────────────────────────────┐
153
+ │ Test Adequacy Criteria │
154
+ ├─────────────────────────────────────────────────────────────┤
155
+ │ │
156
+ │ Coverage-Based Criteria │
157
+ │ ├── Statement Coverage: % of statements executed │
158
+ │ ├── Branch Coverage: % of branches taken │
159
+ │ ├── Condition Coverage: % of conditions evaluated │
160
+ │ └── MC/DC: Modified condition/decision coverage │
161
+ │ │
162
+ │ Fault-Based Criteria │
163
+ │ ├── Mutation Score: % of mutants killed │
164
+ │ └── Fault Seeding: % of seeded faults found │
165
+ │ │
166
+ │ Requirements-Based Criteria │
167
+ │ └── Requirements Coverage: % of requirements tested │
168
+ │ │
169
+ │ Risk-Based Criteria │
170
+ │ └── Risk Coverage: % of high-risk items tested │
171
+ │ │
172
+ │ Stopping Rules: │
173
+ │ • Achieved target coverage level │
174
+ │ • Defect discovery rate drops below threshold │
175
+ │ • Budget/time exhausted (with documented risk) │
176
+ │ │
177
+ └─────────────────────────────────────────────────────────────┘
178
+ ```
179
+
180
+ ---
181
+
182
+ ## Static Testing
183
+
184
+ Static testing examines work products (code, documents, requirements) without executing the software. It complements dynamic testing by finding defects earlier in the SDLC.
185
+
186
+ **Reference**: ISTQB CTFL v4.0 Chapter 3, ISO/IEC/IEEE 29119-4
187
+
188
+ ### Types of Static Testing
189
+
190
+ ```
191
+ ┌─────────────────────────────────────────────────────────────┐
192
+ │ Static Testing Types │
193
+ ├─────────────────────────────────────────────────────────────┤
194
+ │ Reviews (Manual) │
195
+ │ ├── Informal Review: Ad-hoc, no formal process │
196
+ │ ├── Walkthrough: Author-led, educational purpose │
197
+ │ ├── Technical Review: Peer-led, find defects │
198
+ │ └── Inspection: Formal, metrics-driven, most rigorous │
199
+ ├─────────────────────────────────────────────────────────────┤
200
+ │ Static Analysis (Tool-based) │
201
+ │ ├── Code Analysis: Linters, complexity analyzers │
202
+ │ ├── Security Analysis: SAST tools (SonarQube, Checkmarx) │
203
+ │ ├── Architecture Analysis: Dependency checks │
204
+ │ └── Data Flow Analysis: Variable usage patterns │
205
+ └─────────────────────────────────────────────────────────────┘
206
+ ```
207
+
208
+ ### Review Process (ISTQB)
209
+
210
+ | Phase | Activities |
211
+ |-------|------------|
212
+ | Planning | Define scope, entry criteria, roles |
213
+ | Initiate Review | Distribute work products |
214
+ | Individual Review | Each reviewer examines independently |
215
+ | Issue Communication | Discuss findings in meeting |
216
+ | Fixing & Reporting | Author fixes, metrics collected |
217
+
218
+ ### Static Analysis Tools by Language
219
+
220
+ | Language | Linting | Security | Complexity |
221
+ |----------|---------|----------|------------|
222
+ | JavaScript/TypeScript | ESLint, Biome | npm audit, Snyk | ESLint complexity rules |
223
+ | Python | Pylint, Ruff, Flake8 | Bandit, Safety | Radon |
224
+ | Java | Checkstyle, PMD | SpotBugs, OWASP DC | JaCoCo |
225
+ | C# | StyleCop, Roslyn | Security Code Scan | NDepend |
226
+ | Go | golangci-lint | gosec | gocyclo |
227
+
228
+ ### When to Use Static Testing
229
+
230
+ | Work Product | Review Type | Tools |
231
+ |--------------|-------------|-------|
232
+ | Requirements | Inspection, Walkthrough | - |
233
+ | Design Documents | Technical Review | Architecture tools |
234
+ | Code | Technical Review, Tool Analysis | Linters, SAST |
235
+ | Test Plans | Walkthrough | - |
236
+ | User Documentation | Walkthrough | Spell/grammar checkers |
237
+
238
+ ### Code Review Checklist
239
+
240
+ ```
241
+ ┌─────────────────────────────────────────────────────────────┐
242
+ │ Code Review Focus Areas │
243
+ ├─────────────────────────────────────────────────────────────┤
244
+ │ Functionality │
245
+ │ ├── Does the code do what it's supposed to do? │
246
+ │ ├── Are edge cases handled? │
247
+ │ └── Is error handling appropriate? │
248
+ ├─────────────────────────────────────────────────────────────┤
249
+ │ Maintainability │
250
+ │ ├── Is the code readable and well-organized? │
251
+ │ ├── Are names meaningful? │
252
+ │ └── Is complexity manageable? │
253
+ ├─────────────────────────────────────────────────────────────┤
254
+ │ Security │
255
+ │ ├── Input validation present? │
256
+ │ ├── No hardcoded secrets? │
257
+ │ └── SQL injection / XSS prevention? │
258
+ ├─────────────────────────────────────────────────────────────┤
259
+ │ Performance │
260
+ │ ├── No obvious inefficiencies? │
261
+ │ ├── Resource cleanup (connections, files)? │
262
+ │ └── Appropriate data structures? │
263
+ └─────────────────────────────────────────────────────────────┘
264
+ ```
265
+
266
+ ### Integration with CI/CD
267
+
268
+ ```yaml
269
+ # Example: Static analysis in CI pipeline
270
+ static-analysis:
271
+ stage: test
272
+ script:
273
+ - npm run lint # Linting
274
+ - npm run lint:security # Security analysis
275
+ - npx sonarqube-scanner # Quality gates
276
+ rules:
277
+ - if: $CI_PIPELINE_SOURCE == "push"
278
+ ```
279
+
280
+ ---
281
+
282
+ ## Test Design Techniques
283
+
284
+ Test design techniques are methods for deriving and selecting test cases. ISTQB and ISO/IEC/IEEE 29119 categorize them into three main approaches.
285
+
286
+ **Reference**: ISTQB CTFL v4.0 Chapter 4, ISO/IEC/IEEE 29119-4
287
+
288
+ ### Technique Categories
289
+
290
+ ```
291
+ ┌─────────────────────────────────────────────────────────────┐
292
+ │ Test Design Technique Categories │
293
+ ├─────────────────────────────────────────────────────────────┤
294
+ │ Specification-Based (Black-Box) │
295
+ │ └── Derive tests from requirements/specifications │
296
+ ├─────────────────────────────────────────────────────────────┤
297
+ │ Structure-Based (White-Box) │
298
+ │ └── Derive tests from internal code structure │
299
+ ├─────────────────────────────────────────────────────────────┤
300
+ │ Experience-Based │
301
+ │ └── Derive tests from tester knowledge and intuition │
302
+ └─────────────────────────────────────────────────────────────┘
303
+ ```
304
+
305
+ ### Specification-Based Techniques (Black-Box)
306
+
307
+ #### 1. Equivalence Partitioning (EP)
308
+
309
+ Divides input data into partitions where all values should be treated the same by the system.
310
+
311
+ ```
312
+ Input: Age (valid range: 18-65)
313
+
314
+ ┌─────────────┬─────────────┬─────────────┐
315
+ │ Invalid │ Valid │ Invalid │
316
+ │ < 18 │ 18 - 65 │ > 65 │
317
+ ├─────────────┼─────────────┼─────────────┤
318
+ │ Partition 1│ Partition 2│ Partition 3│
319
+ │ Test: 10 │ Test: 30 │ Test: 70 │
320
+ └─────────────┴─────────────┴─────────────┘
321
+
322
+ Coverage: At least 1 test case per partition
323
+ ```
324
+
325
+ ```python
326
+ # Python Example: Equivalence Partitioning
327
+ def test_age_validation():
328
+ validator = AgeValidator(min_age=18, max_age=65)
329
+
330
+ # Partition 1: Below minimum (invalid)
331
+ assert validator.is_valid(10) == False
332
+
333
+ # Partition 2: Valid range
334
+ assert validator.is_valid(30) == True
335
+
336
+ # Partition 3: Above maximum (invalid)
337
+ assert validator.is_valid(70) == False
338
+ ```
339
+
340
+ #### 2. Boundary Value Analysis (BVA)
341
+
342
+ Tests at the boundaries of equivalence partitions where defects are most likely.
343
+
344
+ ```
345
+ Input: Quantity (valid range: 1-100)
346
+
347
+ 0 1 2 ... 99 100 101
348
+ │ │ │ │ │ │
349
+ ▼ ▼ ▼ ▼ ▼ ▼
350
+ Invalid Valid Valid Valid Valid Invalid
351
+ (boundary)(boundary) (boundary)(boundary)
352
+
353
+ Test Values: 0, 1, 2, 99, 100, 101
354
+ ```
355
+
356
+ ```typescript
357
+ // TypeScript Example: Boundary Value Analysis
358
+ describe('Quantity Validation', () => {
359
+ const validator = new QuantityValidator(1, 100);
360
+
361
+ // Lower boundary
362
+ it('rejects 0 (below minimum)', () => {
363
+ expect(validator.isValid(0)).toBe(false);
364
+ });
365
+
366
+ it('accepts 1 (minimum boundary)', () => {
367
+ expect(validator.isValid(1)).toBe(true);
368
+ });
369
+
370
+ it('accepts 2 (above minimum)', () => {
371
+ expect(validator.isValid(2)).toBe(true);
372
+ });
373
+
374
+ // Upper boundary
375
+ it('accepts 99 (below maximum)', () => {
376
+ expect(validator.isValid(99)).toBe(true);
377
+ });
378
+
379
+ it('accepts 100 (maximum boundary)', () => {
380
+ expect(validator.isValid(100)).toBe(true);
381
+ });
382
+
383
+ it('rejects 101 (above maximum)', () => {
384
+ expect(validator.isValid(101)).toBe(false);
385
+ });
386
+ });
387
+ ```
388
+
389
+ #### 3. Decision Table Testing
390
+
391
+ Captures complex business rules with multiple conditions.
392
+
393
+ ```
394
+ Discount Rules:
395
+ - Premium member: 20% discount
396
+ - Order > $100: 10% discount
397
+ - Both conditions: 25% discount (not cumulative)
398
+
399
+ ┌─────────────────┬──────┬──────┬──────┬──────┐
400
+ │ Conditions │ TC1 │ TC2 │ TC3 │ TC4 │
401
+ ├─────────────────┼──────┼──────┼──────┼──────┤
402
+ │ Premium Member │ N │ Y │ N │ Y │
403
+ │ Order > $100 │ N │ N │ Y │ Y │
404
+ ├─────────────────┼──────┼──────┼──────┼──────┤
405
+ │ Actions │ │ │ │ │
406
+ ├─────────────────┼──────┼──────┼──────┼──────┤
407
+ │ Discount % │ 0% │ 20% │ 10% │ 25% │
408
+ └─────────────────┴──────┴──────┴──────┴──────┘
409
+ ```
410
+
411
+ ```csharp
412
+ // C# Example: Decision Table Testing
413
+ [TestClass]
414
+ public class DiscountCalculatorTests
415
+ {
416
+ private DiscountCalculator _calculator;
417
+
418
+ [TestInitialize]
419
+ public void Setup() => _calculator = new DiscountCalculator();
420
+
421
+ [TestMethod]
422
+ public void Calculate_NotPremium_SmallOrder_NoDiscount()
423
+ {
424
+ var result = _calculator.Calculate(isPremium: false, orderAmount: 50);
425
+ Assert.AreEqual(0, result.DiscountPercent);
426
+ }
427
+
428
+ [TestMethod]
429
+ public void Calculate_Premium_SmallOrder_20PercentDiscount()
430
+ {
431
+ var result = _calculator.Calculate(isPremium: true, orderAmount: 50);
432
+ Assert.AreEqual(20, result.DiscountPercent);
433
+ }
434
+
435
+ [TestMethod]
436
+ public void Calculate_NotPremium_LargeOrder_10PercentDiscount()
437
+ {
438
+ var result = _calculator.Calculate(isPremium: false, orderAmount: 150);
439
+ Assert.AreEqual(10, result.DiscountPercent);
440
+ }
441
+
442
+ [TestMethod]
443
+ public void Calculate_Premium_LargeOrder_25PercentDiscount()
444
+ {
445
+ var result = _calculator.Calculate(isPremium: true, orderAmount: 150);
446
+ Assert.AreEqual(25, result.DiscountPercent);
447
+ }
448
+ }
449
+ ```
450
+
451
+ #### 4. State Transition Testing
452
+
453
+ Tests behavior changes based on system states and transitions.
454
+
455
+ ```
456
+ Order State Machine:
457
+
458
+ ┌─────────┐ place() ┌───────────┐ pay() ┌────────┐
459
+ │ Draft │──────────────▶│ Pending │───────────▶│ Paid │
460
+ └─────────┘ └───────────┘ └────────┘
461
+ │ │ │
462
+ │ cancel() │ cancel() │ ship()
463
+ ▼ ▼ ▼
464
+ ┌───────────┐ ┌───────────┐ ┌──────────┐
465
+ │ Cancelled │ │ Cancelled │ │ Shipped │
466
+ └───────────┘ └───────────┘ └──────────┘
467
+
468
+ State Transition Table:
469
+ ┌───────────┬─────────┬───────────┬───────────┬───────────┐
470
+ │ Current │ place() │ pay() │ ship() │ cancel() │
471
+ ├───────────┼─────────┼───────────┼───────────┼───────────┤
472
+ │ Draft │ Pending │ Invalid │ Invalid │ Cancelled │
473
+ │ Pending │ Invalid │ Paid │ Invalid │ Cancelled │
474
+ │ Paid │ Invalid │ Invalid │ Shipped │ Invalid │
475
+ │ Shipped │ Invalid │ Invalid │ Invalid │ Invalid │
476
+ │ Cancelled │ Invalid │ Invalid │ Invalid │ Invalid │
477
+ └───────────┴─────────┴───────────┴───────────┴───────────┘
478
+ ```
479
+
480
+ ```python
481
+ # Python Example: State Transition Testing
482
+ class TestOrderStateMachine:
483
+ def test_draft_to_pending_on_place(self):
484
+ order = Order(state="draft")
485
+ order.place()
486
+ assert order.state == "pending"
487
+
488
+ def test_pending_to_paid_on_pay(self):
489
+ order = Order(state="pending")
490
+ order.pay()
491
+ assert order.state == "paid"
492
+
493
+ def test_paid_to_shipped_on_ship(self):
494
+ order = Order(state="paid")
495
+ order.ship()
496
+ assert order.state == "shipped"
497
+
498
+ def test_invalid_transition_pay_from_draft(self):
499
+ order = Order(state="draft")
500
+ with pytest.raises(InvalidTransitionError):
501
+ order.pay()
502
+
503
+ def test_invalid_transition_cancel_from_shipped(self):
504
+ order = Order(state="shipped")
505
+ with pytest.raises(InvalidTransitionError):
506
+ order.cancel()
507
+ ```
508
+
509
+ #### 5. Use Case Testing
510
+
511
+ Tests complete user scenarios from start to finish.
512
+
513
+ ```
514
+ Use Case: User Login
515
+
516
+ Primary Flow:
517
+ 1. User enters username
518
+ 2. User enters password
519
+ 3. User clicks login
520
+ 4. System validates credentials
521
+ 5. System redirects to dashboard
522
+
523
+ Alternative Flows:
524
+ A1. Invalid credentials → Show error, remain on login
525
+ A2. Account locked → Show locked message
526
+ A3. Password expired → Redirect to password change
527
+
528
+ Test Cases:
529
+ - TC1: Valid credentials → Dashboard (Primary)
530
+ - TC2: Invalid password → Error message (A1)
531
+ - TC3: Invalid username → Error message (A1)
532
+ - TC4: Locked account → Locked message (A2)
533
+ - TC5: Expired password → Password change page (A3)
534
+ ```
535
+
536
+ #### 6. Pairwise Testing (Combinatorial Testing)
537
+
538
+ Tests all possible pairs of input parameter values, reducing test cases while maintaining good coverage.
539
+
540
+ **Reference**: SWEBOK v4.0 - Input Domain-Based Techniques
541
+
542
+ ```
543
+ Example: Login Form with 3 parameters, each with 3 values
544
+
545
+ Parameters:
546
+ - Browser: Chrome, Firefox, Safari
547
+ - OS: Windows, macOS, Linux
548
+ - Language: English, Spanish, French
549
+
550
+ Full Combinatorial: 3 × 3 × 3 = 27 test cases
551
+ Pairwise Coverage: 9 test cases (covers all pairs)
552
+
553
+ ┌──────┬──────────┬─────────┬──────────┐
554
+ │ TC │ Browser │ OS │ Language │
555
+ ├──────┼──────────┼─────────┼──────────┤
556
+ │ 1 │ Chrome │ Windows │ English │
557
+ │ 2 │ Chrome │ macOS │ Spanish │
558
+ │ 3 │ Chrome │ Linux │ French │
559
+ │ 4 │ Firefox │ Windows │ Spanish │
560
+ │ 5 │ Firefox │ macOS │ French │
561
+ │ 6 │ Firefox │ Linux │ English │
562
+ │ 7 │ Safari │ Windows │ French │
563
+ │ 8 │ Safari │ macOS │ English │
564
+ │ 9 │ Safari │ Linux │ Spanish │
565
+ └──────┴──────────┴─────────┴──────────┘
566
+ ```
567
+
568
+ **Tools**: PICT (Microsoft), AllPairs, Jenny
569
+
570
+ ```bash
571
+ # Using PICT (Pairwise Independent Combinatorial Testing)
572
+ # Input file: params.txt
573
+ # Browser: Chrome, Firefox, Safari
574
+ # OS: Windows, macOS, Linux
575
+ # Language: English, Spanish, French
576
+
577
+ pict params.txt > test_cases.txt
578
+ ```
579
+
580
+ #### 7. Data Flow Testing
581
+
582
+ Tests the flow of data through a program by tracking variable definitions and uses.
583
+
584
+ **Reference**: SWEBOK v4.0 - Code-Based Techniques
585
+
586
+ ```
587
+ ┌─────────────────────────────────────────────────────────────┐
588
+ │ Data Flow Terminology │
589
+ ├─────────────────────────────────────────────────────────────┤
590
+ │ │
591
+ │ Definition (def): Variable is assigned a value │
592
+ │ Use (use): Variable's value is accessed │
593
+ │ - c-use: Computational use (in calculation) │
594
+ │ - p-use: Predicate use (in condition) │
595
+ │ │
596
+ │ def-use pair: Path from definition to use │
597
+ │ def-clear path: No redefinition between def and use │
598
+ │ │
599
+ │ Example: │
600
+ │ 1: x = 5 ← def(x) │
601
+ │ 2: y = x + 1 ← c-use(x), def(y) │
602
+ │ 3: if (x > 0) ← p-use(x) │
603
+ │ 4: z = y * 2 ← c-use(y), def(z) │
604
+ │ │
605
+ └─────────────────────────────────────────────────────────────┘
606
+ ```
607
+
608
+ **Coverage Criteria**:
609
+
610
+ | Criterion | Requirement | Strength |
611
+ |-----------|-------------|----------|
612
+ | All-Defs | Every def reaches at least one use | Weak |
613
+ | All-Uses | Every def-use pair is exercised | Medium |
614
+ | All-DU-Paths | All def-clear paths from def to use | Strong |
615
+
616
+ ```python
617
+ # Python Example: Data Flow Testing
618
+ def calculate_discount(price, quantity, is_member):
619
+ # def: total
620
+ total = price * quantity
621
+
622
+ # def: discount
623
+ if is_member: # p-use: is_member
624
+ discount = 0.1 # def: discount (path 1)
625
+ else:
626
+ discount = 0.0 # def: discount (path 2)
627
+
628
+ # c-use: total, discount
629
+ if total > 100: # p-use: total
630
+ discount += 0.05 # c-use: discount, def: discount
631
+
632
+ # c-use: total, discount
633
+ return total * (1 - discount)
634
+
635
+ # Test cases for All-Uses coverage:
636
+ # TC1: is_member=True, total>100 → exercises def@line4, use@line10
637
+ # TC2: is_member=False, total>100 → exercises def@line6, use@line10
638
+ # TC3: is_member=True, total<=100 → exercises def@line4, use@line12
639
+ # TC4: is_member=False, total<=100 → exercises def@line6, use@line12
640
+ ```
641
+
642
+ ### Structure-Based Techniques (White-Box)
643
+
644
+ #### 1. Statement Coverage
645
+
646
+ Ensure every statement is executed at least once.
647
+
648
+ ```
649
+ Code:
650
+ 1 function categorize(score) {
651
+ 2 let result;
652
+ 3 if (score >= 90) {
653
+ 4 result = 'A';
654
+ 5 } else if (score >= 70) {
655
+ 6 result = 'B';
656
+ 7 } else {
657
+ 8 result = 'C';
658
+ 9 }
659
+ 10 return result;
660
+ 11 }
661
+
662
+ 100% Statement Coverage requires tests:
663
+ - Test 1: score = 95 → executes lines 1-4, 10
664
+ - Test 2: score = 80 → executes lines 1-3, 5-6, 10
665
+ - Test 3: score = 50 → executes lines 1-3, 5, 7-10
666
+ ```
667
+
668
+ #### 2. Branch Coverage
669
+
670
+ Ensure every branch (decision outcome) is executed.
671
+
672
+ ```
673
+ Code:
674
+ if (a > 0 && b > 0) {
675
+ doSomething();
676
+ }
677
+
678
+ Branches:
679
+ - True branch: a > 0 AND b > 0 is true
680
+ - False branch: a > 0 AND b > 0 is false
681
+
682
+ 100% Branch Coverage:
683
+ - Test 1: a = 1, b = 1 → True branch
684
+ - Test 2: a = 0, b = 1 → False branch (or a = 1, b = 0)
685
+ ```
686
+
687
+ #### 3. Condition Coverage
688
+
689
+ Ensure each condition in a decision is evaluated to both true and false.
690
+
691
+ ```
692
+ Code:
693
+ if (a > 0 && b > 0) { ... }
694
+
695
+ Conditions: (a > 0), (b > 0)
696
+
697
+ 100% Condition Coverage:
698
+ - Test 1: a = 1, b = 1 → (a > 0) = true, (b > 0) = true
699
+ - Test 2: a = 0, b = 0 → (a > 0) = false, (b > 0) = false
700
+
701
+ Note: Does not guarantee branch coverage!
702
+ ```
703
+
704
+ #### 4. MC/DC (Modified Condition/Decision Coverage)
705
+
706
+ Each condition independently affects the decision outcome. Required for safety-critical systems.
707
+
708
+ ```
709
+ Code:
710
+ if (a && b) { ... }
711
+
712
+ MC/DC Requirements:
713
+ 1. Each condition evaluated to true and false
714
+ 2. Each condition independently affects outcome
715
+
716
+ Test Cases:
717
+ - Test 1: a = true, b = true → Decision = true
718
+ - Test 2: a = false, b = true → Decision = false (a changed outcome)
719
+ - Test 3: a = true, b = false → Decision = false (b changed outcome)
720
+ ```
721
+
722
+ ### Technique Selection Guide
723
+
724
+ | Technique | Best For | Test Level |
725
+ |-----------|----------|------------|
726
+ | Equivalence Partitioning | Input validation, ranges | UT, IT |
727
+ | Boundary Value Analysis | Numeric limits, dates | UT, IT |
728
+ | Decision Table | Complex business rules | UT, IT, ST |
729
+ | State Transition | Workflows, status changes | IT, ST |
730
+ | Use Case Testing | User scenarios | ST, E2E |
731
+ | Pairwise Testing | Multi-parameter combinations | IT, ST |
732
+ | Data Flow Testing | Variable lifecycle verification | UT |
733
+ | Statement Coverage | Basic code coverage | UT |
734
+ | Branch Coverage | Decision logic | UT |
735
+ | MC/DC | Safety-critical systems | UT |
736
+
737
+ ---
738
+
739
+ ## Experience-Based Testing
740
+
741
+ Experience-based testing leverages the tester's knowledge, skills, and intuition to design and execute tests. It complements systematic techniques.
742
+
743
+ **Reference**: ISTQB CTFL v4.0 Section 4.4
744
+
745
+ ### Types of Experience-Based Testing
746
+
747
+ #### 1. Exploratory Testing
748
+
749
+ Simultaneous test design, execution, and learning. The tester explores the system without predefined scripts.
750
+
751
+ ```
752
+ ┌─────────────────────────────────────────────────────────────┐
753
+ │ Exploratory Testing Session │
754
+ ├─────────────────────────────────────────────────────────────┤
755
+ │ Charter: "Explore the checkout process focusing on │
756
+ │ payment failure scenarios" │
757
+ ├─────────────────────────────────────────────────────────────┤
758
+ │ Time-box: 60 minutes │
759
+ ├─────────────────────────────────────────────────────────────┤
760
+ │ Notes: │
761
+ │ - Tested expired credit card → Got generic error │
762
+ │ - Tested insufficient funds → Same generic error │
763
+ │ - Found: No specific error messages for different failures │
764
+ │ - Bug: Retry with same card doesn't clear previous error │
765
+ ├─────────────────────────────────────────────────────────────┤
766
+ │ Bugs Found: 2 │
767
+ │ Areas for Further Testing: Error message specificity │
768
+ └─────────────────────────────────────────────────────────────┘
769
+ ```
770
+
771
+ **Session-Based Test Management (SBTM)**:
772
+
773
+ | Element | Description |
774
+ |---------|-------------|
775
+ | Charter | Mission statement for the session |
776
+ | Time-box | Fixed duration (typically 60-90 min) |
777
+ | Session Notes | Observations, questions, bugs found |
778
+ | Debrief | Review findings with team |
779
+
780
+ #### 2. Error Guessing
781
+
782
+ Anticipate defects based on experience with similar systems or common mistakes.
783
+
784
+ ```
785
+ Common Error Categories to Guess:
786
+
787
+ ┌─────────────────────────────────────────────────────────────┐
788
+ │ Input Errors │
789
+ │ ├── Empty/null inputs │
790
+ │ ├── Very long strings │
791
+ │ ├── Special characters (', ", <, >, &, etc.) │
792
+ │ ├── Unicode/emoji characters │
793
+ │ └── Negative numbers where positive expected │
794
+ ├─────────────────────────────────────────────────────────────┤
795
+ │ Boundary Errors │
796
+ │ ├── Off-by-one errors │
797
+ │ ├── Integer overflow/underflow │
798
+ │ ├── Date boundaries (leap years, month ends) │
799
+ │ └── Array index out of bounds │
800
+ ├─────────────────────────────────────────────────────────────┤
801
+ │ State Errors │
802
+ │ ├── Operations on deleted records │
803
+ │ ├── Concurrent modifications │
804
+ │ ├── Session timeout during operation │
805
+ │ └── Browser back button after submission │
806
+ ├─────────────────────────────────────────────────────────────┤
807
+ │ Environment Errors │
808
+ │ ├── Network timeout/disconnection │
809
+ │ ├── Low disk space │
810
+ │ ├── Database connection pool exhaustion │
811
+ │ └── Time zone differences │
812
+ └─────────────────────────────────────────────────────────────┘
813
+ ```
814
+
815
+ #### 3. Checklist-Based Testing
816
+
817
+ Use predefined checklists based on experience and standards.
818
+
819
+ ```markdown
820
+ # API Endpoint Testing Checklist
821
+
822
+ ## Authentication & Authorization
823
+ - [ ] Endpoint rejects unauthenticated requests
824
+ - [ ] Endpoint rejects expired tokens
825
+ - [ ] Endpoint enforces role-based access
826
+ - [ ] Different user roles see appropriate data
827
+
828
+ ## Input Validation
829
+ - [ ] Required fields are validated
830
+ - [ ] Data types are enforced
831
+ - [ ] String length limits enforced
832
+ - [ ] Malicious input sanitized (XSS, SQL injection)
833
+
834
+ ## Response Handling
835
+ - [ ] Success responses have correct status codes
836
+ - [ ] Error responses have meaningful messages
837
+ - [ ] Response format matches API documentation
838
+ - [ ] Pagination works correctly
839
+
840
+ ## Performance
841
+ - [ ] Response time under load is acceptable
842
+ - [ ] No N+1 query problems
843
+ - [ ] Large datasets handled gracefully
844
+ ```
845
+
846
+ ### When to Use Experience-Based Testing
847
+
848
+ | Scenario | Recommended Technique |
849
+ |----------|----------------------|
850
+ | New feature exploration | Exploratory Testing |
851
+ | Legacy system with no documentation | Exploratory Testing |
852
+ | Known problematic areas | Error Guessing |
853
+ | Regression testing | Checklist-Based |
854
+ | Time pressure / quick validation | Error Guessing |
855
+ | Compliance verification | Checklist-Based |
856
+
857
+ ### Combining with Systematic Techniques
858
+
859
+ ```
860
+ ┌─────────────────────────────────────────────────────────────┐
861
+ │ Optimal Testing Approach │
862
+ ├─────────────────────────────────────────────────────────────┤
863
+ │ │
864
+ │ Systematic Techniques Experience-Based │
865
+ │ (70-80% of effort) (20-30% of effort) │
866
+ │ │
867
+ │ ┌──────────────────┐ ┌──────────────────┐ │
868
+ │ │ Equivalence Part.│ │ Exploratory │ │
869
+ │ │ Boundary Value │ + │ Error Guessing │ │
870
+ │ │ Decision Tables │ │ Checklists │ │
871
+ │ └──────────────────┘ └──────────────────┘ │
872
+ │ │
873
+ │ Provides: Provides: │
874
+ │ - Coverage - Edge cases │
875
+ │ - Repeatability - Real-world scenarios │
876
+ │ - Documentation - Quick feedback │
877
+ │ │
878
+ └─────────────────────────────────────────────────────────────┘
879
+ ```
880
+
881
+ ---
882
+
883
+ ## Risk-Based Testing
884
+
885
+ Risk-based testing prioritizes testing efforts based on the likelihood and impact of potential failures.
886
+
887
+ **Reference**: ISTQB CTFL v4.0 Section 5.2
888
+
889
+ ### Risk Assessment
890
+
891
+ #### Risk Formula
892
+
893
+ ```
894
+ Risk Level = Likelihood × Impact
895
+
896
+ ┌─────────────────────────────────────────────────────────────┐
897
+ │ Risk Matrix │
898
+ ├─────────────┬───────────────────────────────────────────────┤
899
+ │ │ Impact │
900
+ │ Likelihood │ Low (1) Medium (2) High (3) │
901
+ ├─────────────┼───────────────────────────────────────────────┤
902
+ │ High (3) │ Medium(3) High(6) Critical(9) │
903
+ │ Medium (2) │ Low(2) Medium(4) High(6) │
904
+ │ Low (1) │ Low(1) Low(2) Medium(3) │
905
+ └─────────────┴───────────────────────────────────────────────┘
906
+ ```
907
+
908
+ #### Risk Factors
909
+
910
+ **Likelihood Factors** (Technical Risk):
911
+ - Complexity of the feature
912
+ - New/unfamiliar technology
913
+ - Code quality metrics
914
+ - Developer experience
915
+ - Frequency of changes
916
+ - Integration complexity
917
+
918
+ **Impact Factors** (Business Risk):
919
+ - Revenue impact
920
+ - User base affected
921
+ - Regulatory compliance
922
+ - Brand reputation
923
+ - Data security/privacy
924
+ - Operational criticality
925
+
926
+ ### Risk-Based Test Prioritization
927
+
928
+ ```
929
+ Example: E-commerce Application
930
+
931
+ ┌──────────────────────┬─────────┬─────────┬───────┬──────────┐
932
+ │ Feature │Likelihood│ Impact │ Risk │ Priority │
933
+ ├──────────────────────┼─────────┼─────────┼───────┼──────────┤
934
+ │ Payment Processing │ 2 │ 3 │ 6 │ 1 │
935
+ │ User Authentication │ 2 │ 3 │ 6 │ 2 │
936
+ │ Shopping Cart │ 2 │ 2 │ 4 │ 3 │
937
+ │ Product Search │ 1 │ 2 │ 2 │ 4 │
938
+ │ Product Reviews │ 1 │ 1 │ 1 │ 5 │
939
+ │ Wishlist │ 1 │ 1 │ 1 │ 6 │
940
+ └──────────────────────┴─────────┴─────────┴───────┴──────────┘
941
+
942
+ Test Effort Allocation:
943
+ - Critical (Risk 6+): 50% of test effort, most thorough coverage
944
+ - Medium (Risk 3-5): 30% of test effort, standard coverage
945
+ - Low (Risk 1-2): 20% of test effort, basic coverage
946
+ ```
947
+
948
+ ### Risk-Based Test Planning
949
+
950
+ ```markdown
951
+ # Risk-Based Test Plan Template
952
+
953
+ ## 1. Risk Identification
954
+ List all features/components and their risk factors.
955
+
956
+ ## 2. Risk Analysis
957
+ Calculate risk scores using Likelihood × Impact.
958
+
959
+ ## 3. Test Prioritization
960
+ | Priority | Features | Test Depth |
961
+ |----------|----------|------------|
962
+ | P1 | Payment, Auth | Full coverage, all techniques |
963
+ | P2 | Cart, Checkout | Standard coverage |
964
+ | P3 | Search, Browse | Basic happy path |
965
+ | P4 | Reviews, Wishlist | Minimal, smoke tests |
966
+
967
+ ## 4. Risk Mitigation
968
+ - P1 features: 100% automated tests, manual exploratory
969
+ - P2 features: 80% automated, sample manual tests
970
+ - P3 features: Key scenarios automated
971
+ - P4 features: Basic smoke tests only
972
+
973
+ ## 5. Residual Risk Acceptance
974
+ Document accepted risks for low-priority features.
975
+ ```
976
+
977
+ ### Continuous Risk Assessment
978
+
979
+ ```
980
+ ┌─────────────────────────────────────────────────────────────┐
981
+ │ Continuous Risk Re-evaluation │
982
+ ├─────────────────────────────────────────────────────────────┤
983
+ │ │
984
+ │ Sprint Start ──▶ During Sprint ──▶ Sprint End │
985
+ │ │ │ │ │
986
+ │ ▼ ▼ ▼ │
987
+ │ Initial Risk Update based on: Review: │
988
+ │ Assessment - Defects found - Actual vs Expected │
989
+ │ - Code changes - Adjust for next │
990
+ │ - New requirements sprint │
991
+ │ │
992
+ └─────────────────────────────────────────────────────────────┘
993
+ ```
994
+
995
+ ---
996
+
997
+ ## Specialized Testing
998
+
999
+ Modern software development requires specialized testing types beyond traditional categories.
1000
+
1001
+ ### Contract Testing
1002
+
1003
+ Verifies that services communicate correctly according to agreed contracts. Essential for microservices architectures.
1004
+
1005
+ ```
1006
+ ┌─────────────────────────────────────────────────────────────┐
1007
+ │ Consumer-Driven Contract Testing │
1008
+ ├─────────────────────────────────────────────────────────────┤
1009
+ │ │
1010
+ │ Consumer Provider │
1011
+ │ (Frontend) (API) │
1012
+ │ │ │ │
1013
+ │ │ 1. Define expectations │ │
1014
+ │ │─────────────────────────────▶ │ │
1015
+ │ │ │ │
1016
+ │ │ 2. Generate contract │ │
1017
+ │ │ (Pact file) │ │
1018
+ │ │ │ │
1019
+ │ │ 3. Share contract │ │
1020
+ │ │─────────────────────────────▶ │ │
1021
+ │ │ │ │
1022
+ │ │ 4. Provider verifies │
1023
+ │ │ against contract │
1024
+ │ │ │ │
1025
+ └─────────────────────────────────────────────────────────────┘
1026
+ ```
1027
+
1028
+ **Tools**: Pact, Spring Cloud Contract, Postman
1029
+
1030
+ ```typescript
1031
+ // Consumer Test (Pact.js Example)
1032
+ describe('User API Contract', () => {
1033
+ it('returns user by ID', async () => {
1034
+ await provider.addInteraction({
1035
+ state: 'user with ID 123 exists',
1036
+ uponReceiving: 'a request for user 123',
1037
+ withRequest: {
1038
+ method: 'GET',
1039
+ path: '/users/123'
1040
+ },
1041
+ willRespondWith: {
1042
+ status: 200,
1043
+ body: {
1044
+ id: '123',
1045
+ name: Matchers.string('John Doe'),
1046
+ email: Matchers.email()
1047
+ }
1048
+ }
1049
+ });
1050
+
1051
+ const user = await userClient.getUser('123');
1052
+ expect(user.id).toBe('123');
1053
+ });
1054
+ });
1055
+ ```
1056
+
1057
+ ### Mutation Testing
1058
+
1059
+ Evaluates test suite quality by introducing small changes (mutants) to the code and checking if tests detect them.
1060
+
1061
+ ```
1062
+ ┌─────────────────────────────────────────────────────────────┐
1063
+ │ Mutation Testing │
1064
+ ├─────────────────────────────────────────────────────────────┤
1065
+ │ │
1066
+ │ Original Code: Mutant (change operator): │
1067
+ │ if (a > b) if (a >= b) ← Boundary mutant │
1068
+ │ if (a > b) if (a < b) ← Negation mutant │
1069
+ │ return a + b; return a - b; ← Arithmetic mutant │
1070
+ │ return true; return false; ← Return value mutant │
1071
+ │ │
1072
+ ├─────────────────────────────────────────────────────────────┤
1073
+ │ Mutation Score = (Killed Mutants / Total Mutants) × 100 │
1074
+ │ │
1075
+ │ - Killed: Test failed → Good, test detected the change │
1076
+ │ - Survived: Test passed → Bad, test missed the defect │
1077
+ │ │
1078
+ │ Target: > 80% mutation score for critical code │
1079
+ └─────────────────────────────────────────────────────────────┘
1080
+ ```
1081
+
1082
+ **Tools**: Stryker (JS/TS), PITest (Java), mutmut (Python)
1083
+
1084
+ ```bash
1085
+ # Run mutation testing with Stryker
1086
+ npx stryker run
1087
+
1088
+ # Example output:
1089
+ # Mutation score: 85.7%
1090
+ # Killed: 180 Survived: 30 No coverage: 10
1091
+ ```
1092
+
1093
+ ### Chaos Engineering
1094
+
1095
+ Proactively tests system resilience by injecting failures in production or staging environments.
1096
+
1097
+ ```
1098
+ ┌─────────────────────────────────────────────────────────────┐
1099
+ │ Chaos Engineering Principles │
1100
+ ├─────────────────────────────────────────────────────────────┤
1101
+ │ │
1102
+ │ 1. Define "steady state" (normal behavior metrics) │
1103
+ │ 2. Hypothesize steady state continues during chaos │
1104
+ │ 3. Introduce real-world events: │
1105
+ │ - Server failures │
1106
+ │ - Network latency/partition │
1107
+ │ - Resource exhaustion │
1108
+ │ - Clock skew │
1109
+ │ 4. Try to disprove the hypothesis │
1110
+ │ 5. Minimize blast radius (start small) │
1111
+ │ │
1112
+ └─────────────────────────────────────────────────────────────┘
1113
+ ```
1114
+
1115
+ **Tools**: Chaos Monkey, Gremlin, Litmus, Chaos Toolkit
1116
+
1117
+ ```yaml
1118
+ # Chaos Toolkit Experiment Example
1119
+ title: "Service resilience when database is slow"
1120
+ description: "Verify the service degrades gracefully"
1121
+
1122
+ steady-state-hypothesis:
1123
+ title: "Service responds within SLA"
1124
+ probes:
1125
+ - name: "service-responds"
1126
+ type: probe
1127
+ provider:
1128
+ type: http
1129
+ url: "http://service/health"
1130
+ timeout: 3
1131
+
1132
+ method:
1133
+ - name: "inject-db-latency"
1134
+ type: action
1135
+ provider:
1136
+ type: process
1137
+ path: "tc"
1138
+ arguments: "qdisc add dev eth0 root netem delay 500ms"
1139
+ pauses:
1140
+ after: 30
1141
+
1142
+ rollbacks:
1143
+ - name: "remove-latency"
1144
+ type: action
1145
+ provider:
1146
+ type: process
1147
+ path: "tc"
1148
+ arguments: "qdisc del dev eth0 root"
1149
+ ```
1150
+
1151
+ ### Property-Based Testing
1152
+
1153
+ Generates random test inputs based on properties the code should satisfy.
1154
+
1155
+ ```python
1156
+ # Python Example with Hypothesis
1157
+ from hypothesis import given, strategies as st
1158
+
1159
+ # Property: Sorting should be idempotent
1160
+ @given(st.lists(st.integers()))
1161
+ def test_sort_idempotent(xs):
1162
+ sorted_once = sorted(xs)
1163
+ sorted_twice = sorted(sorted_once)
1164
+ assert sorted_once == sorted_twice
1165
+
1166
+ # Property: Sorted list should have same elements
1167
+ @given(st.lists(st.integers()))
1168
+ def test_sort_preserves_elements(xs):
1169
+ sorted_xs = sorted(xs)
1170
+ assert sorted(xs) == sorted(sorted_xs)
1171
+ assert len(xs) == len(sorted_xs)
1172
+
1173
+ # Property: JSON encode/decode roundtrip
1174
+ @given(st.dictionaries(st.text(), st.integers()))
1175
+ def test_json_roundtrip(d):
1176
+ assert json.loads(json.dumps(d)) == d
1177
+ ```
1178
+
1179
+ **Tools**: Hypothesis (Python), fast-check (JS/TS), QuickCheck (Haskell), FsCheck (C#)
1180
+
1181
+ ### Visual Regression Testing
1182
+
1183
+ Detects unintended visual changes in UI components.
1184
+
1185
+ ```
1186
+ ┌─────────────────────────────────────────────────────────────┐
1187
+ │ Visual Regression Testing │
1188
+ ├─────────────────────────────────────────────────────────────┤
1189
+ │ │
1190
+ │ 1. Capture baseline screenshots │
1191
+ │ 2. Run tests, capture new screenshots │
1192
+ │ 3. Compare pixel-by-pixel or perceptually │
1193
+ │ 4. Flag differences for review │
1194
+ │ │
1195
+ │ ┌─────────────┐ ┌─────────────┐ ┌─────────────┐ │
1196
+ │ │ Baseline │ → │ Current │ → │ Diff │ │
1197
+ │ │ Screenshot │ │ Screenshot │ │ Report │ │
1198
+ │ └─────────────┘ └─────────────┘ └─────────────┘ │
1199
+ │ │
1200
+ └─────────────────────────────────────────────────────────────┘
1201
+ ```
1202
+
1203
+ **Tools**: Percy, Chromatic, BackstopJS, Playwright visual comparisons
1204
+
1205
+ ```typescript
1206
+ // Playwright Visual Regression Example
1207
+ test('homepage visual regression', async ({ page }) => {
1208
+ await page.goto('/');
1209
+ await expect(page).toHaveScreenshot('homepage.png', {
1210
+ maxDiffPixels: 100 // Allow minor differences
1211
+ });
1212
+ });
1213
+
1214
+ test('button component visual regression', async ({ page }) => {
1215
+ await page.goto('/components/button');
1216
+ const button = page.locator('[data-testid="primary-button"]');
1217
+ await expect(button).toHaveScreenshot('primary-button.png');
1218
+ });
1219
+ ```
1220
+
1221
+ ### Accessibility Testing (a11y)
1222
+
1223
+ Ensures applications are usable by people with disabilities.
1224
+
1225
+ ```
1226
+ ┌─────────────────────────────────────────────────────────────┐
1227
+ │ Accessibility Testing Checklist │
1228
+ ├─────────────────────────────────────────────────────────────┤
1229
+ │ WCAG 2.1 Guidelines │
1230
+ │ ├── Perceivable │
1231
+ │ │ ├── Alt text for images │
1232
+ │ │ ├── Captions for video │
1233
+ │ │ └── Sufficient color contrast │
1234
+ │ ├── Operable │
1235
+ │ │ ├── Keyboard navigation │
1236
+ │ │ ├── Focus indicators visible │
1237
+ │ │ └── No keyboard traps │
1238
+ │ ├── Understandable │
1239
+ │ │ ├── Clear labels and instructions │
1240
+ │ │ ├── Predictable navigation │
1241
+ │ │ └── Error identification │
1242
+ │ └── Robust │
1243
+ │ ├── Valid HTML │
1244
+ │ └── ARIA attributes correct │
1245
+ └─────────────────────────────────────────────────────────────┘
1246
+ ```
1247
+
1248
+ **Tools**: axe-core, Pa11y, WAVE, Lighthouse
1249
+
1250
+ ```typescript
1251
+ // Playwright + axe-core Example
1252
+ import AxeBuilder from '@axe-core/playwright';
1253
+
1254
+ test('homepage accessibility', async ({ page }) => {
1255
+ await page.goto('/');
1256
+
1257
+ const results = await new AxeBuilder({ page })
1258
+ .withTags(['wcag2a', 'wcag2aa'])
1259
+ .analyze();
1260
+
1261
+ expect(results.violations).toEqual([]);
1262
+ });
1263
+ ```
1264
+
1265
+ ### Additional Specialized Testing Types (SWEBOK)
1266
+
1267
+ The following test types are defined in SWEBOK v4.0 as test objectives:
1268
+
1269
+ #### Installation Testing
1270
+
1271
+ Verifies that the software installs correctly in the target environment.
1272
+
1273
+ ```
1274
+ ┌─────────────────────────────────────────────────────────────┐
1275
+ │ Installation Testing Checklist │
1276
+ ├─────────────────────────────────────────────────────────────┤
1277
+ │ │
1278
+ │ Pre-Installation │
1279
+ │ ├── Prerequisites verified (OS, runtime, dependencies) │
1280
+ │ ├── Disk space requirements met │
1281
+ │ └── Permissions and access rights confirmed │
1282
+ │ │
1283
+ │ Installation Process │
1284
+ │ ├── Fresh installation succeeds │
1285
+ │ ├── Upgrade from previous version succeeds │
1286
+ │ ├── Custom installation options work │
1287
+ │ └── Silent/unattended installation works │
1288
+ │ │
1289
+ │ Post-Installation │
1290
+ │ ├── Application launches correctly │
1291
+ │ ├── Configuration files created properly │
1292
+ │ ├── Registry/system settings correct │
1293
+ │ └── Uninstallation removes all components │
1294
+ │ │
1295
+ └─────────────────────────────────────────────────────────────┘
1296
+ ```
1297
+
1298
+ #### Alpha and Beta Testing
1299
+
1300
+ | Phase | Participants | Environment | Purpose |
1301
+ |-------|--------------|-------------|---------|
1302
+ | **Alpha** | Internal users, developers | Development site | Early validation, major issues |
1303
+ | **Beta** | External users, customers | Customer site | Real-world validation, feedback |
1304
+ | **Open Beta** | General public | Various | Wide exposure, stress testing |
1305
+
1306
+ #### Recovery Testing
1307
+
1308
+ Tests the system's ability to recover from failures.
1309
+
1310
+ ```
1311
+ ┌─────────────────────────────────────────────────────────────┐
1312
+ │ Recovery Testing Scenarios │
1313
+ ├─────────────────────────────────────────────────────────────┤
1314
+ │ │
1315
+ │ Hardware Failures │
1316
+ │ ├── Power outage during transaction │
1317
+ │ ├── Disk failure and RAID recovery │
1318
+ │ └── Network disconnection and reconnection │
1319
+ │ │
1320
+ │ Software Failures │
1321
+ │ ├── Application crash recovery │
1322
+ │ ├── Database connection loss and reconnect │
1323
+ │ └── Service restart behavior │
1324
+ │ │
1325
+ │ Data Recovery │
1326
+ │ ├── Backup and restore procedures │
1327
+ │ ├── Transaction rollback │
1328
+ │ └── Point-in-time recovery │
1329
+ │ │
1330
+ │ Metrics: │
1331
+ │ • Recovery Time Objective (RTO): Max acceptable downtime │
1332
+ │ • Recovery Point Objective (RPO): Max acceptable data loss │
1333
+ │ │
1334
+ └─────────────────────────────────────────────────────────────┘
1335
+ ```
1336
+
1337
+ #### Configuration Testing
1338
+
1339
+ Tests the system under different configurations.
1340
+
1341
+ ```
1342
+ Configuration Matrix Example:
1343
+
1344
+ ┌──────────────────┬─────────┬─────────┬─────────┐
1345
+ │ Configuration │ Config A│ Config B│ Config C│
1346
+ ├──────────────────┼─────────┼─────────┼─────────┤
1347
+ │ Memory │ 4 GB │ 8 GB │ 16 GB │
1348
+ │ Database │ SQLite │ MySQL │ PostgreSQL│
1349
+ │ Cache │ None │ Redis │ Memcached│
1350
+ │ Load Balancer │ None │ Nginx │ HAProxy │
1351
+ └──────────────────┴─────────┴─────────┴─────────┘
1352
+
1353
+ Test each supported configuration combination.
1354
+ ```
1355
+
1356
+ #### Back-to-Back Testing
1357
+
1358
+ Compares outputs of multiple implementations with identical inputs.
1359
+
1360
+ ```
1361
+ ┌─────────────────────────────────────────────────────────────┐
1362
+ │ Back-to-Back Testing │
1363
+ ├─────────────────────────────────────────────────────────────┤
1364
+ │ │
1365
+ │ Use Cases: │
1366
+ │ ├── Comparing new version against old version │
1367
+ │ ├── Comparing optimized code against reference impl │
1368
+ │ ├── Cross-platform consistency verification │
1369
+ │ └── Validating refactored code behavior │
1370
+ │ │
1371
+ │ Process: │
1372
+ │ ┌─────────┐ ┌─────────────┐ ┌──────────┐ │
1373
+ │ │ Input │────▶│ Version A │────▶│ Output A │──┐ │
1374
+ │ │ Data │ └─────────────┘ └──────────┘ │ │
1375
+ │ │ │ ┌─────────────┐ ┌──────────┐ ▼ │
1376
+ │ │ │────▶│ Version B │────▶│ Output B │─▶Compare │
1377
+ │ └─────────┘ └─────────────┘ └──────────┘ │
1378
+ │ │
1379
+ └─────────────────────────────────────────────────────────────┘
1380
+ ```
1381
+
1382
+ #### Usability Testing
1383
+
1384
+ Evaluates how easily users can learn and use the system.
1385
+
1386
+ ```
1387
+ ┌─────────────────────────────────────────────────────────────┐
1388
+ │ Usability Testing Methods │
1389
+ ├─────────────────────────────────────────────────────────────┤
1390
+ │ │
1391
+ │ Observational Methods │
1392
+ │ ├── Think-aloud protocol │
1393
+ │ ├── Eye tracking │
1394
+ │ └── Session recording │
1395
+ │ │
1396
+ │ Task-Based Methods │
1397
+ │ ├── Task completion rate │
1398
+ │ ├── Time on task │
1399
+ │ └── Error rate │
1400
+ │ │
1401
+ │ Survey Methods │
1402
+ │ ├── System Usability Scale (SUS) │
1403
+ │ ├── Net Promoter Score (NPS) │
1404
+ │ └── Post-task questionnaires │
1405
+ │ │
1406
+ │ Key Metrics: │
1407
+ │ • Learnability: Time to complete first task │
1408
+ │ • Efficiency: Time to complete after learning │
1409
+ │ • Memorability: Performance after period of non-use │
1410
+ │ • Satisfaction: User rating scores │
1411
+ │ │
1412
+ └─────────────────────────────────────────────────────────────┘
1413
+ ```
1414
+
1415
+ ### Specialized Testing Summary
1416
+
1417
+ | Type | Purpose | When to Use |
1418
+ |------|---------|-------------|
1419
+ | Contract Testing | API compatibility | Microservices |
1420
+ | Mutation Testing | Test quality assessment | Critical code paths |
1421
+ | Chaos Engineering | Resilience validation | Production systems |
1422
+ | Property-Based | Edge case discovery | Algorithms, parsers |
1423
+ | Visual Regression | UI consistency | Frontend changes |
1424
+ | Accessibility | Inclusive design | All user-facing apps |
1425
+ | Installation | Deployment verification | Release candidates |
1426
+ | Alpha/Beta | Early user validation | Pre-release phases |
1427
+ | Recovery | Failure recovery | Business-critical systems |
1428
+ | Configuration | Multi-config support | Cross-platform apps |
1429
+ | Back-to-Back | Version comparison | Migrations, refactoring |
1430
+ | Usability | User experience | User-facing applications |
1431
+
1432
+ ---
1433
+
1434
+ ## Test-Related Measures
1435
+
1436
+ Quantitative measures for evaluating both the software under test and the quality of testing itself.
1437
+
1438
+ **Reference**: SWEBOK v4.0 Section 5.4
1439
+
1440
+ ### Program Evaluation Measures
1441
+
1442
+ #### Fault Density
1443
+
1444
+ ```
1445
+ Fault Density = Total Faults / Size
1446
+
1447
+ Where Size can be:
1448
+ - KLOC (Thousands of Lines of Code)
1449
+ - Function Points
1450
+ - Story Points
1451
+
1452
+ Industry Benchmarks:
1453
+ ┌─────────────────────┬────────────────────────────┐
1454
+ │ Quality Level │ Faults per KLOC │
1455
+ ├─────────────────────┼────────────────────────────┤
1456
+ │ Typical │ 1 - 25 │
1457
+ │ Good │ 0.5 - 1 │
1458
+ │ Excellent │ < 0.5 │
1459
+ │ Safety-Critical │ < 0.1 │
1460
+ └─────────────────────┴────────────────────────────┘
1461
+ ```
1462
+
1463
+ #### Reliability Growth Models
1464
+
1465
+ Track defect discovery rate over time to predict remaining defects.
1466
+
1467
+ ```
1468
+ ┌─────────────────────────────────────────────────────────────┐
1469
+ │ Reliability Growth Curve │
1470
+ ├─────────────────────────────────────────────────────────────┤
1471
+ │ │
1472
+ │ Defects │
1473
+ │ Found │
1474
+ │ │ ╭──────────────────────────────── │
1475
+ │ │ ╭─╯ │
1476
+ │ │ ╭╯ │
1477
+ │ │ ╭╯ │
1478
+ │ │╭╯ │
1479
+ │ ├╯ │
1480
+ │ └──────────────────────────────────────▶ Time │
1481
+ │ │
1482
+ │ As testing progresses: │
1483
+ │ • Defect discovery rate decreases │
1484
+ │ • Curve approaches asymptote (total defects) │
1485
+ │ • Remaining defects can be estimated │
1486
+ │ │
1487
+ │ Common Models: │
1488
+ │ • Goel-Okumoto: Exponential │
1489
+ │ • Musa: Logarithmic │
1490
+ │ • Jelinski-Moranda: De-eutrophication │
1491
+ │ │
1492
+ └─────────────────────────────────────────────────────────────┘
1493
+ ```
1494
+
1495
+ ### Test Evaluation Measures
1496
+
1497
+ #### Fault Seeding
1498
+
1499
+ Insert known faults to measure test effectiveness.
1500
+
1501
+ ```
1502
+ Fault Detection Effectiveness = Seeded Faults Found / Total Seeded Faults
1503
+
1504
+ If tests find 80% of seeded faults, estimate:
1505
+ - Similar detection rate for real faults
1506
+ - Remaining faults ≈ Found faults / Detection rate
1507
+
1508
+ Example:
1509
+ - Seeded 20 faults, tests found 16 (80%)
1510
+ - Found 40 real faults during testing
1511
+ - Estimated total real faults ≈ 40 / 0.8 = 50
1512
+ - Estimated remaining ≈ 10 faults
1513
+ ```
1514
+
1515
+ #### Coverage Metrics Summary
1516
+
1517
+ | Metric | Formula | Target |
1518
+ |--------|---------|--------|
1519
+ | Statement Coverage | Executed statements / Total statements | ≥ 70% |
1520
+ | Branch Coverage | Executed branches / Total branches | ≥ 60% |
1521
+ | Condition Coverage | Conditions evaluated T & F / Total conditions | ≥ 80% |
1522
+ | MC/DC | Conditions independently affecting decision | 100% (safety-critical) |
1523
+ | Requirements Coverage | Tested requirements / Total requirements | 100% |
1524
+ | Mutation Score | Killed mutants / Total mutants | ≥ 80% |
1525
+
1526
+ ### Testing Process Metrics
1527
+
1528
+ ```
1529
+ ┌─────────────────────────────────────────────────────────────┐
1530
+ │ Key Testing Metrics │
1531
+ ├─────────────────────────────────────────────────────────────┤
1532
+ │ │
1533
+ │ Efficiency Metrics │
1534
+ │ ├── Test Case Productivity = Tests created / Effort │
1535
+ │ ├── Defect Detection Rate = Defects found / Test hours │
1536
+ │ └── Automation Rate = Automated tests / Total tests │
1537
+ │ │
1538
+ │ Effectiveness Metrics │
1539
+ │ ├── Defect Leakage = Prod defects / Total defects │
1540
+ │ ├── Test Effectiveness = Defects found / Defects present │
1541
+ │ └── Phase Containment = Defects found in phase / Injected │
1542
+ │ │
1543
+ │ Progress Metrics │
1544
+ │ ├── Test Execution Rate = Tests run / Tests planned │
1545
+ │ ├── Pass Rate = Tests passed / Tests executed │
1546
+ │ └── Blocking Rate = Blocked tests / Total tests │
1547
+ │ │
1548
+ └─────────────────────────────────────────────────────────────┘
1549
+ ```
1550
+
1551
+ ---
1552
+
1553
+ ## Defect Management
1554
+
1555
+ Systematic tracking and management of defects throughout the testing lifecycle.
1556
+
1557
+ **Reference**: ISTQB CTFL v4.0 Section 5.5, ISO/IEC/IEEE 29119-3
1558
+
1559
+ ### Defect Lifecycle
1560
+
1561
+ ```
1562
+ ┌─────────────────────────────────────────────────────────────┐
1563
+ │ Defect Lifecycle │
1564
+ ├─────────────────────────────────────────────────────────────┤
1565
+ │ │
1566
+ │ ┌────────┐ ┌────────┐ ┌──────────┐ │
1567
+ │ │ New │───▶│ Open │───▶│ In Progress│ │
1568
+ │ └────────┘ └────────┘ └──────────┘ │
1569
+ │ │ │ │
1570
+ │ │ ▼ │
1571
+ │ │ ┌──────────┐ │
1572
+ │ │ │ Fixed │ │
1573
+ │ │ └──────────┘ │
1574
+ │ │ │ │
1575
+ │ │ ▼ │
1576
+ │ │ ┌──────────┐ ┌──────────┐ │
1577
+ │ │ │ Verified │───▶│ Closed │ │
1578
+ │ │ └──────────┘ └──────────┘ │
1579
+ │ │ │ │
1580
+ │ │ ▼ │
1581
+ │ │ ┌──────────┐ │
1582
+ │ └───────▶│ Reopened │ │
1583
+ │ └──────────┘ │
1584
+ │ │
1585
+ │ Alternative paths: │
1586
+ │ - New → Rejected (not a bug, duplicate) │
1587
+ │ - Open → Deferred (postponed to later release) │
1588
+ │ - Open → Won't Fix (accepted risk) │
1589
+ │ │
1590
+ └─────────────────────────────────────────────────────────────┘
1591
+ ```
1592
+
1593
+ ### Defect Report Template
1594
+
1595
+ ```markdown
1596
+ # Defect Report
1597
+
1598
+ ## Summary
1599
+ [One-line description of the defect]
1600
+
1601
+ ## ID: BUG-1234
1602
+ ## Priority: P1/P2/P3/P4
1603
+ ## Severity: Critical/High/Medium/Low
1604
+
1605
+ ## Environment
1606
+ - **Version**: 2.3.1
1607
+ - **OS**: Windows 11 / macOS 14.2
1608
+ - **Browser**: Chrome 120
1609
+ - **Device**: Desktop / Mobile
1610
+
1611
+ ## Steps to Reproduce
1612
+ 1. Navigate to login page
1613
+ 2. Enter valid username "testuser"
1614
+ 3. Enter invalid password "wrong123"
1615
+ 4. Click "Login" button
1616
+ 5. Observe error message
1617
+
1618
+ ## Expected Result
1619
+ Error message: "Invalid credentials. Please try again."
1620
+
1621
+ ## Actual Result
1622
+ Generic error: "Something went wrong."
1623
+
1624
+ ## Screenshots/Videos
1625
+ [Attach relevant media]
1626
+
1627
+ ## Additional Information
1628
+ - Occurs consistently (100% reproducible)
1629
+ - Related to ticket: FEAT-456
1630
+ - Log file: [attached]
1631
+ ```
1632
+
1633
+ ### Severity vs Priority
1634
+
1635
+ | Severity | Description | Examples |
1636
+ |----------|-------------|----------|
1637
+ | Critical | System crash, data loss, security breach | App won't start, data corruption |
1638
+ | High | Major feature broken, no workaround | Cannot complete checkout |
1639
+ | Medium | Feature impaired but has workaround | Export fails, manual copy works |
1640
+ | Low | Minor issue, cosmetic | Typo, alignment issue |
1641
+
1642
+ | Priority | Description | Response Time |
1643
+ |----------|-------------|---------------|
1644
+ | P1 | Fix immediately | Same day |
1645
+ | P2 | Fix before release | Within sprint |
1646
+ | P3 | Fix when possible | Next sprint |
1647
+ | P4 | Nice to fix | Backlog |
1648
+
1649
+ ### Defect Metrics
1650
+
1651
+ ```
1652
+ ┌─────────────────────────────────────────────────────────────┐
1653
+ │ Key Defect Metrics │
1654
+ ├─────────────────────────────────────────────────────────────┤
1655
+ │ │
1656
+ │ Defect Density = Total Defects / Size (KLOC or FP) │
1657
+ │ - Industry average: 1-25 defects per KLOC │
1658
+ │ │
1659
+ │ Defect Detection Efficiency (DDE) = │
1660
+ │ Defects found before release / Total defects × 100 │
1661
+ │ - Target: > 90% │
1662
+ │ │
1663
+ │ Defect Removal Efficiency (DRE) = │
1664
+ │ Defects removed / Defects injected × 100 │
1665
+ │ - Target: > 95% │
1666
+ │ │
1667
+ │ Mean Time to Detect (MTTD) = Avg time from injection │
1668
+ │ Mean Time to Resolve (MTTR) = Avg time from report to fix │
1669
+ │ │
1670
+ │ Defect Leakage Rate = Production defects / Total defects │
1671
+ │ - Target: < 5% │
1672
+ │ │
1673
+ └─────────────────────────────────────────────────────────────┘
1674
+ ```
1675
+
1676
+ ### Root Cause Analysis
1677
+
1678
+ ```
1679
+ ┌─────────────────────────────────────────────────────────────┐
1680
+ │ Common Defect Root Causes │
1681
+ ├─────────────────────────────────────────────────────────────┤
1682
+ │ Requirements (35-40%) │
1683
+ │ ├── Ambiguous requirements │
1684
+ │ ├── Missing requirements │
1685
+ │ └── Changed requirements │
1686
+ ├─────────────────────────────────────────────────────────────┤
1687
+ │ Design (20-25%) │
1688
+ │ ├── Incorrect algorithm │
1689
+ │ ├── Integration issues │
1690
+ │ └── Performance not considered │
1691
+ ├─────────────────────────────────────────────────────────────┤
1692
+ │ Code (25-30%) │
1693
+ │ ├── Logic errors │
1694
+ │ ├── Boundary conditions │
1695
+ │ └── Exception handling │
1696
+ ├─────────────────────────────────────────────────────────────┤
1697
+ │ Environment (10-15%) │
1698
+ │ ├── Configuration issues │
1699
+ │ ├── Third-party dependencies │
1700
+ │ └── Data issues │
1701
+ └─────────────────────────────────────────────────────────────┘
1702
+ ```
1703
+
1704
+ ---
1705
+
1706
+ ## Test Process Management
1707
+
1708
+ Structured approach to planning, monitoring, and controlling testing activities.
1709
+
1710
+ **Reference**: ISTQB CTFL v4.0 Chapter 5, ISO/IEC/IEEE 29119-2
1711
+
1712
+ ### Test Planning
1713
+
1714
+ #### Test Plan Components (ISO/IEC/IEEE 29119-3)
1715
+
1716
+ ```
1717
+ ┌─────────────────────────────────────────────────────────────┐
1718
+ │ Test Plan Structure │
1719
+ ├─────────────────────────────────────────────────────────────┤
1720
+ │ │
1721
+ │ 1. Test Plan Identification │
1722
+ │ - Project name, version, date │
1723
+ │ │
1724
+ │ 2. Introduction │
1725
+ │ - Purpose, scope, objectives │
1726
+ │ │
1727
+ │ 3. Test Items │
1728
+ │ - Features to be tested │
1729
+ │ - Features not to be tested │
1730
+ │ │
1731
+ │ 4. Test Approach │
1732
+ │ - Test levels and types │
1733
+ │ - Test techniques │
1734
+ │ - Entry/exit criteria │
1735
+ │ │
1736
+ │ 5. Test Environment │
1737
+ │ - Hardware, software, tools │
1738
+ │ - Test data requirements │
1739
+ │ │
1740
+ │ 6. Test Schedule │
1741
+ │ - Milestones, dependencies │
1742
+ │ │
1743
+ │ 7. Roles and Responsibilities │
1744
+ │ - Team structure, RACI matrix │
1745
+ │ │
1746
+ │ 8. Risks and Contingencies │
1747
+ │ - Risk assessment, mitigation │
1748
+ │ │
1749
+ │ 9. Approvals │
1750
+ │ - Sign-off requirements │
1751
+ │ │
1752
+ └─────────────────────────────────────────────────────────────┘
1753
+ ```
1754
+
1755
+ #### Entry and Exit Criteria
1756
+
1757
+ | Criteria Type | Examples |
1758
+ |---------------|----------|
1759
+ | **Entry Criteria** (start testing) | Requirements approved, code complete, environment ready, test data available |
1760
+ | **Exit Criteria** (stop testing) | All P1/P2 tests passed, coverage target met, no critical defects open |
1761
+
1762
+ ```markdown
1763
+ ## Entry Criteria for System Testing
1764
+ - [ ] All integration tests passed
1765
+ - [ ] Test environment deployed and verified
1766
+ - [ ] Test data prepared and loaded
1767
+ - [ ] Test cases reviewed and approved
1768
+ - [ ] All blockers from IT resolved
1769
+
1770
+ ## Exit Criteria for System Testing
1771
+ - [ ] 100% of critical test cases executed
1772
+ - [ ] 95% of high priority test cases passed
1773
+ - [ ] No Critical or High severity defects open
1774
+ - [ ] Code coverage > 80%
1775
+ - [ ] Performance benchmarks met
1776
+ ```
1777
+
1778
+ ### Test Monitoring and Control
1779
+
1780
+ #### Key Progress Metrics
1781
+
1782
+ ```
1783
+ ┌─────────────────────────────────────────────────────────────┐
1784
+ │ Test Progress Metrics │
1785
+ ├─────────────────────────────────────────────────────────────┤
1786
+ │ │
1787
+ │ Execution Metrics: │
1788
+ │ - Tests Planned: 500 │
1789
+ │ - Tests Executed: 350 (70%) │
1790
+ │ - Tests Passed: 320 (91% of executed) │
1791
+ │ - Tests Failed: 30 (9% of executed) │
1792
+ │ - Tests Blocked: 15 │
1793
+ │ │
1794
+ │ Defect Metrics: │
1795
+ │ - Total Defects Found: 45 │
1796
+ │ - Open Defects: 12 (3 Critical, 5 High, 4 Medium) │
1797
+ │ - Fixed Defects: 28 │
1798
+ │ - Verified Defects: 20 │
1799
+ │ │
1800
+ │ Coverage Metrics: │
1801
+ │ - Requirements Coverage: 85% │
1802
+ │ - Code Coverage: 78% │
1803
+ │ - Risk Coverage: 90% │
1804
+ │ │
1805
+ └─────────────────────────────────────────────────────────────┘
1806
+ ```
1807
+
1808
+ #### Test Dashboard Example
1809
+
1810
+ ```
1811
+ Test Progress Dashboard - Sprint 15
1812
+ ═══════════════════════════════════════════════════════════════
1813
+
1814
+ Test Execution Defect Status
1815
+ █████████████████░░░░ 85% Open: ███░░░░░░░ 12
1816
+ Fixed: ████████░░ 28
1817
+ Passed │████████████████│ 320 Verified: ██████░░░░ 20
1818
+ Failed │██ │ 30
1819
+ Blocked │█ │ 15 Trend: ↓ (improving)
1820
+
1821
+ Coverage Build Health
1822
+ Requirements: ███████████░ 85% Last Build: ✓ Pass
1823
+ Code: ████████░░░░ 78% Unit Tests: 245/245 ✓
1824
+ Risk Items: █████████░░░ 90% Int Tests: 89/92 ⚠
1825
+ Flaky Rate: 2.1%
1826
+ ```
1827
+
1828
+ ### Test Completion
1829
+
1830
+ #### Test Summary Report
1831
+
1832
+ ```markdown
1833
+ # Test Summary Report
1834
+
1835
+ ## Project: [Project Name]
1836
+ ## Version: [Version Number]
1837
+ ## Test Period: [Start Date] - [End Date]
1838
+
1839
+ ## Executive Summary
1840
+ [Brief overview of testing activities and outcomes]
1841
+
1842
+ ## Test Scope
1843
+ - Features tested: [list]
1844
+ - Features not tested: [list with justification]
1845
+
1846
+ ## Test Results Summary
1847
+
1848
+ | Test Level | Planned | Executed | Passed | Failed | Pass Rate |
1849
+ |------------|---------|----------|--------|--------|-----------|
1850
+ | Unit | 500 | 500 | 498 | 2 | 99.6% |
1851
+ | Integration| 150 | 150 | 145 | 5 | 96.7% |
1852
+ | System | 200 | 195 | 188 | 7 | 96.4% |
1853
+ | E2E | 50 | 48 | 46 | 2 | 95.8% |
1854
+
1855
+ ## Defect Summary
1856
+
1857
+ | Severity | Found | Fixed | Open | Deferred |
1858
+ |----------|-------|-------|------|----------|
1859
+ | Critical | 2 | 2 | 0 | 0 |
1860
+ | High | 8 | 7 | 1 | 0 |
1861
+ | Medium | 15 | 12 | 2 | 1 |
1862
+ | Low | 20 | 10 | 5 | 5 |
1863
+
1864
+ ## Coverage Analysis
1865
+ - Requirements coverage: 95%
1866
+ - Code coverage: 82%
1867
+ - Risk coverage: 100% (all high-risk items tested)
1868
+
1869
+ ## Open Issues and Risks
1870
+ 1. [Issue 1]: Impact and mitigation
1871
+ 2. [Issue 2]: Impact and mitigation
1872
+
1873
+ ## Recommendations
1874
+ 1. [Recommendation 1]
1875
+ 2. [Recommendation 2]
1876
+
1877
+ ## Conclusion
1878
+ [Final assessment and release recommendation]
1879
+
1880
+ ## Sign-off
1881
+ - QA Lead: [Name, Date]
1882
+ - Dev Lead: [Name, Date]
1883
+ - Product Owner: [Name, Date]
1884
+ ```
1885
+
1886
+ ### Test Process Improvement
1887
+
1888
+ ```
1889
+ ┌─────────────────────────────────────────────────────────────┐
1890
+ │ Continuous Improvement Cycle │
1891
+ ├─────────────────────────────────────────────────────────────┤
1892
+ │ │
1893
+ │ ┌───────────┐ │
1894
+ │ │ Plan │ │
1895
+ │ └─────┬─────┘ │
1896
+ │ │ │
1897
+ │ ▼ │
1898
+ │ ┌───────────┐ ┌───────────┐ │
1899
+ │ │ Act │◀───────▶│ Do │ │
1900
+ │ └───────────┘ └─────┬─────┘ │
1901
+ │ ▲ │ │
1902
+ │ │ ▼ │
1903
+ │ ┌─────┴─────┐ │
1904
+ │ │ Check │ │
1905
+ │ └───────────┘ │
1906
+ │ │
1907
+ │ Retrospective Questions: │
1908
+ │ - What went well? │
1909
+ │ - What could be improved? │
1910
+ │ - What actions will we take? │
1911
+ │ │
1912
+ └─────────────────────────────────────────────────────────────┘
1913
+ ```
1914
+
1915
+ ---
1916
+
1917
+ ## Code Examples by Test Level
1918
+
1919
+ ### Unit Testing Example
1920
+
1921
+ ```csharp
1922
+ // C# Example
1923
+ [TestClass]
1924
+ public class UserValidatorTests
1925
+ {
1926
+ private UserValidator _validator;
1927
+
1928
+ [TestInitialize]
1929
+ public void Setup()
1930
+ {
1931
+ _validator = new UserValidator();
1932
+ }
1933
+
1934
+ [TestMethod]
1935
+ public void ValidateEmail_ValidFormat_ReturnsTrue()
1936
+ {
1937
+ // Arrange
1938
+ var email = "user@example.com";
1939
+
1940
+ // Act
1941
+ var result = _validator.ValidateEmail(email);
1942
+
1943
+ // Assert
1944
+ Assert.IsTrue(result);
1945
+ }
1946
+
1947
+ [TestMethod]
1948
+ public void ValidateEmail_InvalidFormat_ReturnsFalse()
1949
+ {
1950
+ // Arrange
1951
+ var email = "invalid-email";
1952
+
1953
+ // Act
1954
+ var result = _validator.ValidateEmail(email);
1955
+
1956
+ // Assert
1957
+ Assert.IsFalse(result);
1958
+ }
1959
+ }
1960
+ ```
1961
+
1962
+ ```typescript
1963
+ // TypeScript Example
1964
+ describe('UserValidator', () => {
1965
+ let validator: UserValidator;
1966
+
1967
+ beforeEach(() => {
1968
+ validator = new UserValidator();
1969
+ });
1970
+
1971
+ describe('validateEmail', () => {
1972
+ it('should return true for valid email format', () => {
1973
+ const result = validator.validateEmail('user@example.com');
1974
+ expect(result).toBe(true);
1975
+ });
1976
+
1977
+ it('should return false for invalid email format', () => {
1978
+ const result = validator.validateEmail('invalid-email');
1979
+ expect(result).toBe(false);
1980
+ });
1981
+ });
1982
+ });
1983
+ ```
1984
+
1985
+ ### Integration Testing Example
1986
+
1987
+ ```csharp
1988
+ // C# Integration Test Example with Test Database
1989
+ [TestClass]
1990
+ public class UserRepositoryIntegrationTests
1991
+ {
1992
+ private TestDbContext _dbContext;
1993
+ private UserRepository _repository;
1994
+
1995
+ [TestInitialize]
1996
+ public async Task Setup()
1997
+ {
1998
+ // Use test database (e.g., SQLite in-memory or Testcontainers)
1999
+ _dbContext = TestDbContextFactory.Create();
2000
+ _repository = new UserRepository(_dbContext);
2001
+ await _dbContext.Database.EnsureCreatedAsync();
2002
+ }
2003
+
2004
+ [TestCleanup]
2005
+ public async Task Cleanup()
2006
+ {
2007
+ await _dbContext.DisposeAsync();
2008
+ }
2009
+
2010
+ [TestMethod]
2011
+ public async Task CreateUser_WithValidData_PersistsToDatabase()
2012
+ {
2013
+ // Arrange
2014
+ var user = new User { Name = "Test User", Email = "test@example.com" };
2015
+
2016
+ // Act
2017
+ await _repository.CreateAsync(user);
2018
+ var savedUser = await _repository.GetByIdAsync(user.Id);
2019
+
2020
+ // Assert
2021
+ Assert.IsNotNull(savedUser);
2022
+ Assert.AreEqual("Test User", savedUser.Name);
2023
+ }
2024
+ }
2025
+ ```
2026
+
2027
+ ### System Testing Example
2028
+
2029
+ ```csharp
2030
+ // System Test Example: Complete Resource Processing Flow
2031
+ [TestClass]
2032
+ public class ResourceProcessingSystemTests
2033
+ {
2034
+ private HttpClient _client;
2035
+ private TestEnvironment _env;
2036
+
2037
+ [TestInitialize]
2038
+ public async Task Setup()
2039
+ {
2040
+ _env = await TestEnvironment.CreateAsync();
2041
+ _client = _env.CreateAuthenticatedClient();
2042
+ }
2043
+
2044
+ [TestMethod]
2045
+ public async Task ProcessResource_CompleteFlow_CompletedSuccessfully()
2046
+ {
2047
+ // Arrange: Create test data
2048
+ var item = await _env.CreateTestItem(value: 100);
2049
+ var user = await _env.CreateTestUser();
2050
+
2051
+ // Act: Execute complete processing flow
2052
+ // Step 1: Create request
2053
+ var requestResponse = await _client.PostAsync("/api/requests",
2054
+ new { itemId = item.Id, quantity = 2 });
2055
+ Assert.AreEqual(HttpStatusCode.OK, requestResponse.StatusCode);
2056
+
2057
+ // Step 2: Submit processing
2058
+ var processResponse = await _client.PostAsync("/api/processes",
2059
+ new { requestId = requestResponse.RequestId, userId = user.Id });
2060
+ var process = await processResponse.Content.ReadAsAsync<Process>();
2061
+ Assert.AreEqual(HttpStatusCode.Created, processResponse.StatusCode);
2062
+
2063
+ // Step 3: Confirm completion
2064
+ var confirmResponse = await _client.PostAsync($"/api/processes/{process.Id}/confirm",
2065
+ new { confirmationType = "standard", amount = 200 });
2066
+ Assert.AreEqual(HttpStatusCode.OK, confirmResponse.StatusCode);
2067
+
2068
+ // Assert: Verify final state
2069
+ var finalProcess = await _client.GetAsync($"/api/processes/{process.Id}");
2070
+ var result = await finalProcess.Content.ReadAsAsync<Process>();
2071
+
2072
+ Assert.AreEqual(ProcessStatus.Completed, result.Status);
2073
+ Assert.AreEqual(200, result.TotalAmount);
2074
+ Assert.IsNotNull(result.Confirmation);
2075
+ }
2076
+ }
2077
+ ```
2078
+
2079
+ ### E2E Testing Example
2080
+
2081
+ ```typescript
2082
+ // Playwright E2E Test Example
2083
+ import { test, expect } from '@playwright/test';
2084
+
2085
+ test.describe('User Registration Journey', () => {
2086
+ test('should complete registration and login successfully', async ({ page }) => {
2087
+ // Step 1: Navigate to registration page
2088
+ await page.goto('/register');
2089
+
2090
+ // Step 2: Fill registration form
2091
+ await page.fill('[data-testid="email"]', 'newuser@example.com');
2092
+ await page.fill('[data-testid="password"]', 'SecurePass123!');
2093
+ await page.fill('[data-testid="confirm-password"]', 'SecurePass123!');
2094
+ await page.click('[data-testid="register-button"]');
2095
+
2096
+ // Step 3: Verify registration success
2097
+ await expect(page.locator('[data-testid="success-message"]'))
2098
+ .toContainText('Registration successful');
2099
+
2100
+ // Step 4: Login with new account
2101
+ await page.goto('/login');
2102
+ await page.fill('[data-testid="email"]', 'newuser@example.com');
2103
+ await page.fill('[data-testid="password"]', 'SecurePass123!');
2104
+ await page.click('[data-testid="login-button"]');
2105
+
2106
+ // Step 5: Verify login success and dashboard redirect
2107
+ await expect(page).toHaveURL('/dashboard');
2108
+ await expect(page.locator('[data-testid="welcome-message"]'))
2109
+ .toContainText('Welcome, newuser@example.com');
2110
+ });
2111
+ });
2112
+ ```
2113
+
2114
+ ### Containerized Testing Example
2115
+
2116
+ ```csharp
2117
+ // C# Example with Testcontainers
2118
+ public class DatabaseIntegrationTests : IAsyncLifetime
2119
+ {
2120
+ private readonly PostgreSqlContainer _postgres = new PostgreSqlBuilder()
2121
+ .WithImage("postgres:15")
2122
+ .Build();
2123
+
2124
+ public async Task InitializeAsync()
2125
+ {
2126
+ await _postgres.StartAsync();
2127
+ }
2128
+
2129
+ public async Task DisposeAsync()
2130
+ {
2131
+ await _postgres.DisposeAsync();
2132
+ }
2133
+
2134
+ [Fact]
2135
+ public async Task Should_Connect_To_Database()
2136
+ {
2137
+ var connectionString = _postgres.GetConnectionString();
2138
+ // Use connectionString for tests
2139
+ }
2140
+ }
2141
+ ```
2142
+
2143
+ ```python
2144
+ # Python Example with Testcontainers
2145
+ import pytest
2146
+ from testcontainers.postgres import PostgresContainer
2147
+
2148
+ @pytest.fixture(scope="module")
2149
+ def postgres_container():
2150
+ with PostgresContainer("postgres:15") as postgres:
2151
+ yield postgres
2152
+
2153
+ def test_database_connection(postgres_container):
2154
+ connection_url = postgres_container.get_connection_url()
2155
+ # Use connection_url for tests
2156
+ ```
2157
+
2158
+ ```yaml
2159
+ # docker-compose.test.yml
2160
+ version: '3.8'
2161
+ services:
2162
+ app:
2163
+ build: .
2164
+ depends_on:
2165
+ - db
2166
+ - redis
2167
+ - rabbitmq
2168
+ environment:
2169
+ - DATABASE_URL=postgres://test:test@db:5432/testdb
2170
+ - REDIS_URL=redis://redis:6379
2171
+ - RABBITMQ_URL=amqp://guest:guest@rabbitmq:5672
2172
+
2173
+ db:
2174
+ image: postgres:15
2175
+ environment:
2176
+ POSTGRES_USER: test
2177
+ POSTGRES_PASSWORD: test
2178
+ POSTGRES_DB: testdb
2179
+
2180
+ redis:
2181
+ image: redis:7-alpine
2182
+
2183
+ rabbitmq:
2184
+ image: rabbitmq:3-management
2185
+ ```
2186
+
2187
+ ---
2188
+
2189
+ ## Quick Reference Card
2190
+
2191
+ ```
2192
+ ┌─────────────────────────────────────────────────────────────┐
2193
+ │ Reference Standards │
2194
+ ├─────────────────────────────────────────────────────────────┤
2195
+ │ • ISTQB CTFL v4.0 - Testing certification │
2196
+ │ • ISO/IEC/IEEE 29119 - Testing standards │
2197
+ │ • SWEBOK v4.0 - Software engineering knowledge │
2198
+ ├─────────────────────────────────────────────────────────────┤
2199
+ │ Testing Fundamentals (SWEBOK) │
2200
+ ├─────────────────────────────────────────────────────────────┤
2201
+ │ Error → Fault → Failure (cause chain) │
2202
+ │ Oracle Problem: How to know expected result? │
2203
+ │ Limitation: Testing proves presence, not absence of bugs │
2204
+ │ Testability: Controllability + Observability + Isolability │
2205
+ ├─────────────────────────────────────────────────────────────┤
2206
+ │ Testing Framework Options │
2207
+ ├─────────────────────────────────────────────────────────────┤
2208
+ │ ISTQB: UT → IT/SIT → ST → AT/UAT (Enterprise/Compliance) │
2209
+ │ Industry: UT (70%) → IT (20%) → E2E (10%) (Agile/DevOps) │
2210
+ ├─────────────────────────────────────────────────────────────┤
2211
+ │ Testing Levels Summary │
2212
+ ├──────────┬──────────────────────────────────────────────────┤
2213
+ │ UT │ Single unit, isolated, mocked deps, < 100ms │
2214
+ ├──────────┼──────────────────────────────────────────────────┤
2215
+ │ IT/SIT │ Component integration, real DB, 1-10 sec │
2216
+ ├──────────┼──────────────────────────────────────────────────┤
2217
+ │ ST │ Full system, requirement-based (ISTQB only) │
2218
+ ├──────────┼──────────────────────────────────────────────────┤
2219
+ │ E2E │ User journeys, UI to DB, critical paths only │
2220
+ ├──────────┼──────────────────────────────────────────────────┤
2221
+ │ AT/UAT │ Business validation by end users (ISTQB only) │
2222
+ ├──────────┴──────────────────────────────────────────────────┤
2223
+ │ Test Types (ISTQB) │
2224
+ ├─────────────────────────────────────────────────────────────┤
2225
+ │ Functional: Verify system behavior (black-box) │
2226
+ │ Non-Functional: Performance, security, usability │
2227
+ │ Structural: Code coverage, white-box techniques │
2228
+ │ Change-Related: Confirmation & regression testing │
2229
+ ├─────────────────────────────────────────────────────────────┤
2230
+ │ Test Design Techniques │
2231
+ ├─────────────────────────────────────────────────────────────┤
2232
+ │ Black-Box: EP, BVA, Decision Table, State Transition │
2233
+ │ Pairwise Testing, Use Case Testing │
2234
+ │ White-Box: Statement, Branch, Condition, MC/DC │
2235
+ │ Data Flow (All-Defs, All-Uses) │
2236
+ │ Experience: Exploratory, Error Guessing, Checklists │
2237
+ ├─────────────────────────────────────────────────────────────┤
2238
+ │ Coverage Targets │
2239
+ ├─────────────────────────────────────────────────────────────┤
2240
+ │ Line: 70% min / 85% recommended │
2241
+ │ Branch: 60% min / 80% recommended │
2242
+ │ Function: 80% min / 90% recommended │
2243
+ │ Mutation Score: ≥ 80% for critical code │
2244
+ ├─────────────────────────────────────────────────────────────┤
2245
+ │ Specialized Testing Types │
2246
+ ├─────────────────────────────────────────────────────────────┤
2247
+ │ Contract: API compatibility for microservices │
2248
+ │ Mutation: Test quality via code mutations │
2249
+ │ Chaos: Resilience via failure injection │
2250
+ │ Property-Based: Random inputs based on properties │
2251
+ │ Visual Regression: UI screenshot comparison │
2252
+ │ Accessibility: WCAG compliance validation │
2253
+ │ Installation: Deployment verification │
2254
+ │ Recovery: Failure recovery (RTO/RPO) │
2255
+ │ Configuration: Multi-config testing │
2256
+ │ Usability: User experience (SUS, NPS) │
2257
+ ├─────────────────────────────────────────────────────────────┤
2258
+ │ Test-Related Measures │
2259
+ ├─────────────────────────────────────────────────────────────┤
2260
+ │ Fault Density = Faults / KLOC (target: < 1) │
2261
+ │ Defect Leakage = Prod defects / Total defects (< 5%) │
2262
+ │ Fault Seeding: Insert known faults to measure detection │
2263
+ │ Reliability Growth: Track defect rate over time │
2264
+ └─────────────────────────────────────────────────────────────┘
2265
+ ```
2266
+
2267
+ ---
2268
+
2269
+ ## Related Standards
2270
+
2271
+ - [Testing Standards](../../core/testing-standards.md) - Actionable rules for AI agents
2272
+ - [Testing Pyramid](./testing-pyramid.md) - Detailed pyramid ratios
2273
+ - [Test-Driven Development](../../core/test-driven-development.md) - TDD/BDD/ATDD methodology
2274
+ - [Test Completeness Dimensions](../../core/test-completeness-dimensions.md) - 8-dimension test coverage
2275
+ - [Code Review Checklist](../../core/code-review-checklist.md)
2276
+
2277
+ ---
2278
+
2279
+ ## Version History
2280
+
2281
+ | Version | Date | Changes |
2282
+ |---------|------|---------|
2283
+ | 1.0.0 | 2026-01-29 | Initial creation: Extracted educational content from core/testing-standards.md including Testing Fundamentals, Static Testing, Test Design Techniques, Experience-Based Testing, Risk-Based Testing, Specialized Testing, Test-Related Measures, Defect Management, Test Process Management, Code Examples, and Quick Reference Card. |
2284
+
2285
+ ---
2286
+
2287
+ ## License
2288
+
2289
+ This document is released under [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/).
2290
+
2291
+ **Source**: [universal-dev-standards](https://github.com/AsiaOstrich/universal-dev-standards)