unit testing

Chris Mellon arkanes at gmail.com
Thu Oct 4 21:13:03 CEST 2007

On 10/4/07, brad <byte8bits at gmail.com> wrote:
> Does anyone else feel that unittesting is too much work? Not in general,
> just the official unittest module for small to medium sized projects?
> It seems easier to write some quick methods that are used when needed
> rather than building a program with integrated unittesting. I see the
> value of it (the official unittest that is)... especially when there's a
> lot of source code. But this...
> if len(x) != y:
>     sys.exit('...')
> is a hell of a lot easier and quicker that subclassing unittest.TestCase
> on small projects :)
> Do others do their own "informal" unit testing?

Doctest is commonly given as the alternative to people who feel this
way. Personally, I find that anything worth testing is worth having a
test directory and independent unit tests for.

More information about the Python-list mailing list