[plt-scheme] Re: [maybe off-topic] The theory of testing

From: wooks (wookiz at hotmail.com)
Date: Mon Aug 25 12:12:29 EDT 2008


On Aug 23, 10:45 pm, "Grant Rettke" <gret... at acm.org> wrote:
> Hi folks,
>
> I recently had a good chat with my friend about unit testing. His
> company is thinking of making unit testing part of the "standard
> process". I gave him my take on unit testing, that:
>
> 1. Most developers don't know why they exist.

Of course they do. If there was management support (time and
resourcing) for a proper unit testing process programmers would do it
and the ones that didn't would get found out.

> 2. They are usually not maintained, or only maintained to gain code coverage.

See above on management support.

> 3. Project failure then "proves" that unit tests are pointless

Doesn't follow. All other things being equal a project that doesn't
unit test is more likely to fail than one that does.

> 4. Unit tests go away
>

don't understand that one.

There is alot to be said for having a set of readily runnable
automated tests attached to each program you write and designing those
tests before you write the code.

Boris Beizer's leaves us in no doubt as to where he stands  on the
issue.

"If I could I would legislate a minimum standard  that required
execution under test of every single line of code and every decision's
direction. In case I haven't made myself clear, leaving untested code
in a system is stupid, short-sighted, and irresponsible."


Posted on the users mailing list.