Women in Technology

Hear us Roar



Article:
  Unit Testing with OCUnit
Subject:   Test Driven Development doesn't *always* work
Date:   2004-04-24 15:59:02
From:   gaeldesign
Response to: Test Driven Development

I don't understand why, if you are going to write a full set of tests anyway, you wait until you write a "large chunk of the application".


Because if you are experimenting with software architecture and may be drastically refactoring code or even scrapping it and starting over from scratch, then writing the tests first is far too tedious and drains creativity. I've tried several times to use TDD when starting out with basic software architecture, and it doesn't work for me. It's far easier to get the code to a somewhat useful and stable state, and then write the tests you need to make sure the code is working correctly.


I think TDD is probably great for large apps with large development teams that are working on various chunks of the codebase separately and need to do sanity checks often, but for small-scale developers...especially "one-man" developers like me...TDD is sometimes overkill.


Just my 2c,


Jared

Full Threads Oldest First

Showing messages 1 through 1 of 1.

  • Daniel H. Steinberg photo TDD and Refactoring
    2004-04-26 11:00:05  Daniel H. Steinberg | O'Reilly AuthorO'Reilly Blogger [View]

    I can agree that TDD isn't right for everything and may not be right in your situation. I also am not trying to be argumentative, but TDD seems to be right in the sweetspot of what you are targetting. It can help you discover an appropriate software architecture and it covers your backside if you find you have gone down the wrong path. While you do dramatic refactorings, a suite of tests keeps your app working.



    Of course, I'm a bigot about this. For me, of all of the practices described in XP and related methodologies, TDD was life changing. It was what made my code more robust and flexible.



    D