RFC: Additional functionality for PyUnit

Tim Peters tim.one at home.com
Wed Aug 29 15:11:59 EDT 2001


[MikeK]
> ...
> If PyUnit were to be extended to add a 'globalSetUp' method, run once
> before all other test methods in the test case, and a
> 'globalTearDown', run once after all other test methods in the test
> case, that are in addition to the currently-supported 'setUp' and
> 'tearDown' methods, I'd be very happy.
>
> Or am I missing something that would already give me what I want?

Only 0.49 joking, since PyUnit runs tests in alphabetical order, a quick
hack is to add

    def test_AAAAA_global_setup
and
    def test_zzzzz_global_teardown

methods.

but-that's-only-if-you-want-something-that-works-right-away<wink>-ly
    y'rs  - tim





More information about the Python-list mailing list