diff options
author | Antoine Pitrou <solipsis@pitrou.net> | 2012-04-25 12:58:17 (GMT) |
---|---|---|
committer | Antoine Pitrou <solipsis@pitrou.net> | 2012-04-25 12:58:17 (GMT) |
commit | f99983dacb509125f53358496c4fee9eaf2e67e8 (patch) | |
tree | f7ca15e455a070a0d53b1b722e9f85bcf3a75684 /Lib/unittest/case.py | |
parent | d0bb6aa27507fede6cde3e536bd5edec5cd5dfa4 (diff) | |
parent | b05ac864f048bfeb184e93be71aebd6223a76eec (diff) | |
download | cpython-f99983dacb509125f53358496c4fee9eaf2e67e8.zip cpython-f99983dacb509125f53358496c4fee9eaf2e67e8.tar.gz cpython-f99983dacb509125f53358496c4fee9eaf2e67e8.tar.bz2 |
Issue #14664: It is now possible to use @unittest.skip{If,Unless} on a test class that doesn't inherit from TestCase (i.e. a mixin).
Diffstat (limited to 'Lib/unittest/case.py')
-rw-r--r-- | Lib/unittest/case.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/unittest/case.py b/Lib/unittest/case.py index 5bed868..28f0a2d 100644 --- a/Lib/unittest/case.py +++ b/Lib/unittest/case.py @@ -61,7 +61,7 @@ def skip(reason): Unconditionally skip a test. """ def decorator(test_item): - if not (isinstance(test_item, type) and issubclass(test_item, TestCase)): + if not isinstance(test_item, type): @functools.wraps(test_item) def skip_wrapper(*args, **kwargs): raise SkipTest(reason) |