Issue #14605: Expose importlib.abc.FileLoader and

importlib.machinery.(FileFinder, SourceFileLoader,
_SourcelessFileLoader, ExtensionFileLoader).

This exposes all of importlib's mechanisms that will become public on
the sys module.
This commit is contained in:
Brett Cannon 2012-04-22 19:58:33 -04:00
parent 8c5e920ae3
commit 938d44d59c
17 changed files with 3246 additions and 3076 deletions

View file

@ -1,3 +1,4 @@
import imp
import sys
from test import support
import unittest
@ -13,8 +14,10 @@ class ExtensionModuleCaseSensitivityTest(unittest.TestCase):
good_name = ext_util.NAME
bad_name = good_name.upper()
assert good_name != bad_name
finder = _bootstrap._FileFinder(ext_util.PATH,
_bootstrap._ExtensionFinderDetails())
finder = _bootstrap.FileFinder(ext_util.PATH,
(_bootstrap.ExtensionFileLoader,
_bootstrap._suffix_list(imp.C_EXTENSION),
False))
return finder.find_module(bad_name)
def test_case_sensitive(self):