ID EN
Unittest

addModuleCleanup

Python 3.11

Add a function to be called after tearDownModule() to cleanup resources used during the test class. Functions will be called in reverse order to the order they are added (LIFO). They are called with any arguments and keyword arguments passed into addModuleCleanup() when they are added.

Syntax

PYTHON
unittest.addModuleCleanup(function, /, *args, **kwargs)

See Also

addModuleCleanup()