Move setUpResources and tearDownResources to functions
Bug #504146 reported by
Jonathan Lange
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
testresources |
Fix Released
|
Wishlist
|
Robert Collins |
Bug Description
setUpResources and tearDownResources are useful routines, but by putting them on ResourcedTestCase, it makes it harder for people to re-use them.
In particular, to use them in testtools, you need to use multiple inheritance and get the addCleanup / tearDown balance right.
It would be nice if instead of methods they were functions, or at least staticmethods.
Related branches
lp:~lifeless/testresources/bug-504146
- testresources developers: Pending requested
-
Diff: 163 lines (+66/-30)3 files modifiedNEWS (+4/-0)
lib/testresources/__init__.py (+54/-26)
lib/testresources/tests/test_resourced_test_case.py (+8/-4)
Changed in testresources: | |
status: | New → Triaged |
importance: | Undecided → Wishlist |
To post a comment you must log in.
e.g. http:// paste.ubuntu. com/351088/