unittest.registerResult(result) Register a TestResult object for control-c handling. Registering a result stores
assertNotRegex(text, regex, msg=None) Test that a regex search matches (or does not match) text. In case of
UnexpectedException.example The Example that failed.
unittest.mock.create_autospec(spec, spec_set=False, instance=False, **kwargs) Create a mock object using another object as a
class typing.Any Special type indicating an unconstrained type. Any object
class typing.SupportsInt An ABC with one abstract method __int__.
EnvironmentVarGuard.set(envvar, value) Temporarily set the environment variable envvar to the value of value
shouldStop Set to True when the execution of tests should stop by stop().
exception doctest.DocTestFailure(test, example, got) An exception raised by DocTestRunner to signal that a doctest
tearDown() Method called immediately after the test method has been called and the result recorded. This is called even if the
Page 14 of 28