What We Talk About When We Talk About Unit Testing
Presented at ACCU (23rd April 2015) These days unit testing is considered sexy for programmers. Who'd have thought it? But there is a lot more to effective programmer testing than the fashionable donning of a unit-testing framework: writing Good Unit Tests (GUTs) involves (a lot) more than knowledge of assertion syntax. Testing represents a form of communication and, as such, it offers multiple levels and forms of feedback, not just basic defect detection. Effective unit testing requires an understanding of what forms of feedback and communication are offered by tests, and what styles encourage or discourage such qualities. What styles of test partitioning are common, and yet scale poorly, are uncohesive and are ineffective at properly expressing the behaviour of a class or component? What styles, tricks and tips can be used to make tests more specification-like and scalable to large codebases? How do we choose between scenario-based and property-based test cases?.
★
★
★
★
★
2.39k views • 101 slides