xUnit Test Patters Part1 を通して読みました.

xUnit Test Patterns: Refactoring Test Code (Addison-Wesley Signature Series (Fowler))

xUnit Test Patterns: Refactoring Test Code (Addison-Wesley Signature Series (Fowler))

英語は苦手だけど。。。
それにしても、よくここまでテストの語彙を丁寧にまとめられたもんだ。
これって、すごくねぇ!?


この語彙をキチンとマスターすれば、
RSpecのmathcersのchangeは、Delta Assertionをテスティングフレームワークでサポートしたものかな」
とか
RSpecでテストファイル分割単位は、TestCase Class per Feature単位で行い、
RSpec describeの分割単位は TestCase Class per Fixture単位で行い、
RSpecのbeforeのの際にTest Helperを使ってImplicit Setupすれば、
TestCase Class per FeatureとTestCase Class per Fixtureの折衷案が出来そうなのなところに、
Rspecの高い可能性が!。しかし、ややこしくて、Test as Documentationを保てなくなる?」
みたいな会話ができるのかな?


以下はお気に入りのChapter3 Goals of Test Automation の覚え書き

Tests Should Help Us Improve Quality

Goal:Tests as Specification
Goal:Bug Repellet
Goal:Defect Localization

Tests Should Help Us Understand the SUT

Goal: Tests as Documentation

Tests Should Reduce (and Not Introduce) Risk

Goal:Tests as Safety Net
Goal:Do No Harm

Tests Should Be Easy to Run

Goal:Fully Automated Test
Goal:Self-Checking Test
Goal:Repeatable Test

Tests Should Be Easy to Write and Maintain

Goal:Simple Tests
Goal:Expressive Tests
Goal:Separation of Concerns

Tests Should Require Minimal Maintenace as the System Evolves Around Them

Goal:Robust Test

中身が知りたいなと思ったら、ぜひamazon
xUnit Test Patterns: Refactoring Test Code (Addison-Wesley Signature Series (Fowler))