summaryrefslogtreecommitdiffstats
path: root/Lib/importlib
diff options
context:
space:
mode:
authorBrett Cannon <bcannon@gmail.com>2009-01-27 01:34:30 (GMT)
committerBrett Cannon <bcannon@gmail.com>2009-01-27 01:34:30 (GMT)
commit97c8a07f1d927c218e65bcdfe107e5a306b12a76 (patch)
tree6e4dd87853d42bedeacda1b51faac17bee7f6a8a /Lib/importlib
parentc49715f6827772baf5242f4d33fef716faee497f (diff)
downloadcpython-97c8a07f1d927c218e65bcdfe107e5a306b12a76.zip
cpython-97c8a07f1d927c218e65bcdfe107e5a306b12a76.tar.gz
cpython-97c8a07f1d927c218e65bcdfe107e5a306b12a76.tar.bz2
Make importlib.test.finder_tests an ABC.
Diffstat (limited to 'Lib/importlib')
-rw-r--r--Lib/importlib/test/finder_tests.py28
1 files changed, 14 insertions, 14 deletions
diff --git a/Lib/importlib/test/finder_tests.py b/Lib/importlib/test/finder_tests.py
index 9bbf85a..3cf2c95 100644
--- a/Lib/importlib/test/finder_tests.py
+++ b/Lib/importlib/test/finder_tests.py
@@ -1,39 +1,39 @@
-# top-level.
-# Package.
-# module in pacakge.
-# Package within a package.
-# At least one tests with 'path'.
-# Module that is not handled.
-
+import abc
import unittest
-class FinderTests(unittest.TestCase):
+class FinderTests(unittest.TestCase, metaclass=abc.ABCMeta):
"""Basic tests for a finder to pass."""
+ @abc.abstractmethod
def test_module(self):
# Test importing a top-level module.
- raise NotImplementedError
+ pass
+ @abc.abstractmethod
def test_package(self):
# Test importing a package.
- raise NotImplementedError
+ pass
+ @abc.abstractmethod
def test_module_in_package(self):
# Test importing a module contained within a package.
# A value for 'path' should be used if for a meta_path finder.
- raise NotImplementedError
+ pass
+ @abc.abstractmethod
def test_package_in_package(self):
# Test importing a subpackage.
# A value for 'path' should be used if for a meta_path finder.
- raise NotImplementedError
+ pass
+ @abc.abstractmethod
def test_package_over_module(self):
# Test that packages are chosen over modules.
- raise NotImplementedError
+ pass
+ @abc.abstractmethod
def test_failure(self):
# Test trying to find a module that cannot be handled.
- raise NotImplementedError
+ pass