Skip to content

bpo-36674: Honour the skipping decorators in TestCase.debug() #28446

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

Merged

Conversation

serhiy-storchaka
Copy link
Member

@serhiy-storchaka serhiy-storchaka commented Sep 18, 2021

unittest.TestCase.debug() raises now a SkipTest if the class or
the test method are decorated with the skipping decorator.

Previously it only raised a SkipTest if the test method was decorated
with other decorator in addition to the skipping decorator, or
if SkipTest was explicitly raised in the test or setup methods.

https://bugs.python.org/issue36674

unittest.TestCase.debug() raises now a SkipTest if the class or
the test method are decorated with the skipping decorator.

Previously it only raised a SkipTest if the test method was decorated
with other decorator in addition to the skipping decorator, or
if SkipTest was explicitly raised in the test or setup methods.
@serhiy-storchaka serhiy-storchaka added needs backport to 3.9 only security fixes needs backport to 3.10 only security fixes labels Sep 18, 2021
@serhiy-storchaka serhiy-storchaka added type-bug An unexpected behavior, bug, or error and removed awaiting core review labels Sep 18, 2021
@serhiy-storchaka serhiy-storchaka merged commit dea59cf into python:main Sep 18, 2021
@miss-islington
Copy link
Contributor

Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.9, 3.10.
🐍🍒⛏🤖 I'm not a witch! I'm not a witch!

@serhiy-storchaka serhiy-storchaka deleted the unittest-testcase-debug branch September 18, 2021 12:34
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Sep 18, 2021
…GH-28446)

unittest.TestCase.debug() raises now a SkipTest if the class or
the test method are decorated with the skipping decorator.

Previously it only raised a SkipTest if the test method was decorated
with other decorator in addition to the skipping decorator, or
if SkipTest was explicitly raised in the test or setup methods.
(cherry picked from commit dea59cf)

Co-authored-by: Serhiy Storchaka <[email protected]>
@bedevere-bot
Copy link

GH-28447 is a backport of this pull request to the 3.10 branch.

@bedevere-bot bedevere-bot removed the needs backport to 3.10 only security fixes label Sep 18, 2021
@bedevere-bot
Copy link

GH-28448 is a backport of this pull request to the 3.9 branch.

@bedevere-bot bedevere-bot removed the needs backport to 3.9 only security fixes label Sep 18, 2021
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Sep 18, 2021
…GH-28446)

unittest.TestCase.debug() raises now a SkipTest if the class or
the test method are decorated with the skipping decorator.

Previously it only raised a SkipTest if the test method was decorated
with other decorator in addition to the skipping decorator, or
if SkipTest was explicitly raised in the test or setup methods.
(cherry picked from commit dea59cf)

Co-authored-by: Serhiy Storchaka <[email protected]>
miss-islington added a commit that referenced this pull request Sep 18, 2021
unittest.TestCase.debug() raises now a SkipTest if the class or
the test method are decorated with the skipping decorator.

Previously it only raised a SkipTest if the test method was decorated
with other decorator in addition to the skipping decorator, or
if SkipTest was explicitly raised in the test or setup methods.
(cherry picked from commit dea59cf)

Co-authored-by: Serhiy Storchaka <[email protected]>
miss-islington added a commit that referenced this pull request Sep 18, 2021
unittest.TestCase.debug() raises now a SkipTest if the class or
the test method are decorated with the skipping decorator.

Previously it only raised a SkipTest if the test method was decorated
with other decorator in addition to the skipping decorator, or
if SkipTest was explicitly raised in the test or setup methods.
(cherry picked from commit dea59cf)

Co-authored-by: Serhiy Storchaka <[email protected]>
niyas-sait pushed a commit to niyas-sait/cpython that referenced this pull request Sep 21, 2021
…GH-28446)

unittest.TestCase.debug() raises now a SkipTest if the class or
the test method are decorated with the skipping decorator.

Previously it only raised a SkipTest if the test method was decorated
with other decorator in addition to the skipping decorator, or
if SkipTest was explicitly raised in the test or setup methods.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants