mirror of
https://github.com/python/cpython.git
synced 2025-07-19 01:05:26 +00:00
Factor out helper code from importlib.test.extension.test_path_hook.
This commit is contained in:
parent
36d1f3eb41
commit
534b2cd176
6 changed files with 21 additions and 42 deletions
|
@ -2,6 +2,7 @@ from contextlib import contextmanager
|
|||
import imp
|
||||
import os.path
|
||||
from test.support import unlink
|
||||
import unittest
|
||||
import sys
|
||||
|
||||
|
||||
|
@ -9,7 +10,7 @@ def case_insensitive_tests(class_):
|
|||
"""Class decorator that nullifies tests that require a case-insensitive
|
||||
file system."""
|
||||
if sys.platform not in ('win32', 'darwin', 'cygwin'):
|
||||
return object()
|
||||
return unittest.TestCase
|
||||
else:
|
||||
return class_
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue