Tutorial: "TDD tutorial"
Time: Friday 09:00 - 12:00
Location: SAS Room 13/14
This tutorial demonstrates the development of a small example application using test-driven development and related technologies. The system will comprise a handful of Java classes that exemplify typical components found in enterprise applications, including domain objects and a service layer. The tutorial is structured into three 'iterations' which cover
- state-based testing with JUnit
- interaction-based testing with JUnit and jMock
- deployment in lightweight containers such as PicoContainer and Spring.
The iterations not only introduce the concepts but also provide room for the discussion of trade-offs and edge cases, e.g. how to deal with testing private methods and when not to use dynamic mocks but fake objects.
Attendees gain an understanding of how proper use of test-driven development fosters good design; through decoupling and interface discovery for example. Attendees will also gather a nice catalogue of the most commonly used patterns used in conjunction with test-driven development.