Groups > Borland > Delphi Object Oriented design > Re: Test Driven Design




Re: Test Driven Design

Re: Test Driven Design
Tue, 19 Feb 2008 07:57:09 -050
On Tue, 19 Feb 2008 11:01:51 -0000, Peter Morris wrote:

> With the various checks I was doing it I was barely getting 3 pages written

> every 2 days.  Since I stopped I have been knocking out about 2 or 3 per 
> day.

The justification for TDD is that your product probably spends 90% of
it's coding time in maintenance where you recuperate the initial cost
if you were going to write it once and forget it then it wouldn't make
sense. This is the same reason for every other coding standard.
It also helps during initial development since you, or another
developer, know when some refactoring or other change breaks your
code. You then save time later since you catch problems earlier while
the changes are still fresh in your mind and you haven't wasted your
QA teams time.

The other advantage of TDD is that it serves as documentation of the
expected parameters for a method.

-- 
Marc Rohloff [TeamB]
Post Reply
Re: Test Driven Design
Tue, 19 Feb 2008 10:04:37 -030
Marc Rohloff [TeamB] escreveu:
> The justification for TDD is that your product probably spends 90% of
> it's coding time in maintenance where you recuperate the initial cost
> if you were going to write it once and forget it then it wouldn't make
> sense. This is the same reason for every other coding standard.
> It also helps during initial development since you, or another
> developer, know when some refactoring or other change breaks your
> code. You then save time later since you catch problems earlier while
> the changes are still fresh in your mind and you haven't wasted your
> QA teams time.
> 
> The other advantage of TDD is that it serves as documentation of the
> expected parameters for a method.

It also helps a lot if you already had the tests written before anything else, 
you get feedback about what you're coding faster than if you where to test 
everything by hand. That count X times everytime you make a change (as any 
change can break something you didn't expected and didn't tested by hand).

Post Reply
Test Driven Design
Tue, 19 Feb 2008 11:01:51 -000
Has anyone else found that it takes up too much time?

I've been using it for a website recently.  Adding tests to ensure that you 
can't save invalid objects, ensuring the correct redirect occurs if you save 
a valid object, and so on were all taking far too much time!

With the various checks I was doing it I was barely getting 3 pages written 
every 2 days.  Since I stopped I have been knocking out about 2 or 3 per 
day.

I'm still writing tests for my model + services, but for the pages I think I 
will just write a few tests on the payments pages :-)



Pete 

Post Reply
Re: Test Driven Design
Tue, 19 Feb 2008 13:08:53 -000
The problem as I see it though is that if TDD takes this much longer I would 
never get anything released in a reasonable time!

Post Reply
Re: Test Driven Design
Tue, 19 Feb 2008 14:48:33 -000
My boss has asked me to write the site, then add tests after release, I 
wonder if he will actually give me the time to do that :-)

Post Reply
<< Previous 1 2 3 Next >>
( Page 1 of 3 )
about | contact