Wednesday, October 20, 2004

Test Driven Development

One aspect I cannot understand in TDD is how someone can assume that code is good if it's tested.Code that tests something is still code isn't it?
How do you know if you tested for everything that may go wrong?
If you can get the test correct then you can also get the main code correct.

The only help I see from TDD is that it may allow to see how fixing something here breaks something there. But that means the code is coupled and then how do you test for all this coupling?

-Your code should not be coupled.
-But how do I write GUI code that is uncoupled?
-Don't couple beforehand, instead use runtime registration of event handling.
-How is that uncoupling? How do you test for this chain of events and how do you know how are they going to happen?
-Test everything behind the GUI and leave GUI tests for later.
-What's the point?
-You should not write GUI code and start do some tests.
-Ha?

0 Comments:

Post a Comment

<< Home