I pointed out to someone at work today that PyDev 2.5.0 now offers really cool TDD support. I’m not a huge TDD proponent or anything, but this stirred up a discussion. This guy, let’s call him John, said that “TDD may shorten the time it takes to develop a feature, but sometimes a feature is so urgent we may want to deliver it as quickly as possible and test it later”. Sentences like that make me weep.
This is a companion discussion topic for the original entry at http://amir.rachum.com/blog/2012/04/12/testing-is-not-a-feature/
I disagree that testing is always the right thing to do.
The client might need something urgently, in a situation where correct software delivered a minute too late is as bad as completely broken software delivered in time.
For example, they might be on the verge of going bust and need some simple software developed immediately to make them more efficient and stop them going bust. Assuming testing will make the release later, doing testing in this situation might be a bigger risk than doing none.
(Regarding TDD, some proponents claim that it speeds up development because it helps the design process. If this is the case then my point is still relevant for testing that takes place after the coding is done.)
Thanks for reading!
It's true that sometimes there's an urgent feature that's so urgent we give up testing and that's acceptable, but only if it's an exception. If you test meticulously and give up testing for a small delta change of code - it's okay, as long as you test it afterwards. But shipping without testing as a matter of habit - that's what I'm concerned about.
Sometimes the code isn't required to work when deployed and in those circumstances its OK not to write any tests.
Its the same as refactoring. It isn't something I tell anyone else I am doing, I don't estimate it separately from the other things necessary to get the work done. I just do it because its the right technique for what I need to achieve. If I need a test I write a test, I don't ask permission and I am not going to take technical advice from a project manager.
I heard that test can only tell you there're errors in your codes, it cannot tell you there're no errors in your codes.
At least test codes are not function codes required by customers. I'm interested in finding a way to demonstrate there're no errors in your codes, not through test.
Hey, the devs are trying to do the same thing during last all year from the very start of dev history. They are still tring Orz...
If TDD means Tester Driven Development, I will 100 percent say yes!! If TDD means what it means now, I want to say: wish you very good luck!