[Python-Dev] order of unittest.TestCase execution?

Skip Montanaro skip@pobox.com (Skip Montanaro)
Mon, 12 Nov 2001 15:49:47 +0100


    Andreas> Have you been trying to put the database creation into the
    Andreas> setUp() method that is executed before every testcase ?

No, I was just trying to mimic the structure of the test_xmlrpc.py module.
It put all the cases into one class, so I did to.  I realized I wanted to
run the creation test before the others and noticed that it was executing
them in alphabetical order.  I was just wondering if I could rely on that or
if that was just a quirk of either the current test_support or unittest
implementations and couldn't be relied on.

I can probably fiddle things to work without the implicit ordering, but it's
kind of hard to see how the other tests could succeed if the db creation
test fails, so we might as well run it first. ;-)

Skip