3. What is TDD?
● Writing the test first
● Not a way of life
● Inputs and outputs
● A cycle
Agile Programming Systems # TDD intro
4. The Cycle
1. Add a little test
2. Run all tests and fail
3. Make a little change
4. Run all tests and succeed
Repeat if necessary
5. Refactor to remove duplication
6. Run all tests again and succeed
Repeat if necessary
7. Repeat cycle
Agile Programming Systems # TDD intro
5. The Agile Model Driven
Development (AMDD) lifecycle
Agile Programming Systems # TDD intro
6. Summarising TDD
● Another tool for your toolbox
● Use as you need it
● Can be difficult for beginners
● Frameworks can help
If it's worth building, it's worth testing.
If it's not worth testing, why are you wasting your time
working on it?
Agile Programming Systems # TDD intro
7. Why TDD is Unpopular
● I can’t afford the time
● It’s just as effective to do Test-After
● I’m a developer: I write code, not tests
● The code I’m working on is untestable
● I don’t need tests:
my code is perfect the first time
● I know I should; I just don’t
Agile Programming Systems # TDD intro
8. Agile Programming Systems
●
Extreme Programming
Built around 12 basic practices ranging from pair programming to frequent refactoring, this
approach is more prescriptive than the others.
●
Scrum
Based on the empirical process control model, Scrum programming relies on self-directed
teams and dispenses with much advanced planning, task definition and management
reporting.
●
Crystal
This approach empowers the team to define the development process and refine it in
subsequent iterations until it's stable.
●
Adaptive
Based on adaptive rather than deterministic theories, this approach offers a series of
frameworks to apply adaptive principles and encourage collaboration.
●
Feature-Driven Development
This model-driven, short-iteration process is built around the feature, a unit of work that has
meaning for the client and developer and is small enough to be completed quickly.
●
Dynamic Systems Development Method
Conceived as a methodology for rapid application development, DSDM relies on a set of
principles that include empowered teams, frequent deliverables, incremental development
and integrated testing.
Agile Programming Systems # TDD intro