[TIP] Test discovery for unittest

Michael Foord fuzzyman at voidspace.org.uk
Fri Apr 10 09:28:59 PDT 2009


Olemis Lang wrote:
> [snip...]
>> I am considering your point that this functionality better belongs
>> in a loader than a suite though.
>>     
>
> In that point ... how different would it be from PackageTestLoader ?
>
>   

unittest has no PackageTestLoader. I assume you mean one in dutest? 
Perhaps you can tell us how it is different.

You snipped out without answering my question about how 
DiscoveringTestSuite inhibits reusability - an assertion (no pun 
intended) you made in your previous email.
>> I'm sure there are many good things in dutest. Integration of doctest and
>> unittest is something worth looking at in the future but is not something I
>> have bandwidth for at the moment.
>>     
>
> [...]
>
>   
>> (Particularly as I *personally* feel that
>> docttest is a horrible unit testing tool - but excellent for testing
>> examples in documentation.)
>>
>>     
>
> I personally think that doctest is the most beautiful implementation
> ever made for the following XUnit test patterns :
>
> - Deltha Assertion
> - Scripted Test
> - Recorded Test
> - Data-Driven Test
> - Behavior Verification
> - State Verification
>
> and still allows being meta + agile
>   

Doctest is simply awful for Test Driven Development, the cornerstone of 
agile.

Michael


-- 
http://www.ironpythoninaction.com/
http://www.voidspace.org.uk/blog





More information about the testing-in-python mailing list