Home
subscribe

L'etat, c'est moi

Mere Complexities sells the consulting and development services of me, Paul Wilson.

Conferences

Organising Scotland on Rails
Speaker, RailsConf Europe '08

Archive

Test Driven Development - Frequently Asked Questions II

Q: So is there a simple rule that captures the essence of TDD?

A: Funny you should ask. There is:

Before writing any production code you must have a failing test. Kent Beck (said something like that)

Q: So, these jsps – they don’t seem to have any tests.

A: Ah yes, but they contain no business or presentation logic. All that stuff is in model and helper classes, which are under test.

Q: Ok, so was there a failing test before you wrote those jsps?

A: Well, no…

Q: So…….

A: Ok, you got me. It bothers me, all right? It complicates the build, and I didn’t get round to it.

Q: Didn’t get round to it?

A: Ok, I’ll sort it out. Satisfied?

Q: Not exactly test-first is it?

A: I’m warning you: shut up now.

(Based on a real conversation that happened in my head.)

All