Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unittest: fix the _GetOutOf_testPartExecutor exception kind. Fixes … #6972

Closed
wants to merge 1 commit into from
Closed

unittest: fix the _GetOutOf_testPartExecutor exception kind. Fixes … #6972

wants to merge 1 commit into from

Commits on Mar 26, 2020

  1. unittest: fix the _GetOutOf_testPartExecutor exception kind. Fixes #…

    …6947
    
    `_GetOutOf_testPartExecutor` was introduced in
    04f27d4
    and allow to catch Exception from a unittest TestCase, but as it
    inheritate from `KeyboardInterrupt` it is managed differently by
    unittest (see.
    https://github.com/python/cpython/blob/032de7324e30c6b44ef272cea3be205a3d768759/Lib/unittest/case.py#L61-L62)
    as the `testPartExecutor` reraise it directly. This prevent unittest to
    run the cleanup functions properly.
    
    Since this change enable the teardown methods to be ran properly by
    unittest, the explicit teardown is not required anymore.
    Quentin BEY committed Mar 26, 2020
    Configuration menu
    Copy the full SHA
    e4d9669 View commit details
    Browse the repository at this point in the history