[issue5679] cleanUp stack for unittest

Antoine Pitrou report at bugs.python.org
Sun Apr 5 23:31:39 CEST 2009


Antoine Pitrou <pitrou at free.fr> added the comment:

> So, we are talking about adding a feature that could cause problem whether 
> cleanup is performed before tearDown or after tearDown. Don't we risk 
> confusing developers who are not familiar with the cleanup order?

Well, we could do both. Call cleanups before tearDown (all the while
popping them), call tearDown, and call the new cleanups.

If the cleanup machinery is written carefully enough, you may even be
able to add another cleanup during a cleanup :-)

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue5679>
_______________________________________


More information about the Python-bugs-list mailing list