diff options
author | Jason R. Coombs <jaraco@jaraco.com> | 2021-07-29 21:05:05 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-07-29 21:05:05 -0400 |
commit | aaa83cdfab6817446285e631232f64b394ac6791 (patch) | |
tree | d41195f1412a533b1c7333b99adcc77f171329a1 /Lib/test/test_importlib/test_read.py | |
parent | 851cca8c22795a2f143ad5ebc10adab3c7784ad0 (diff) | |
download | cpython-git-aaa83cdfab6817446285e631232f64b394ac6791.tar.gz |
bpo-44771: Apply changes from importlib_resources 5.2.1 (GH-27436)
* bpo-44771: Apply changes from importlib_resources@3b24bd6307
* Add blurb
* Exclude namespacedata01 from eol conversion.
Diffstat (limited to 'Lib/test/test_importlib/test_read.py')
-rw-r--r-- | Lib/test/test_importlib/test_read.py | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/Lib/test/test_importlib/test_read.py b/Lib/test/test_importlib/test_read.py index f6ec13af62..357980132b 100644 --- a/Lib/test/test_importlib/test_read.py +++ b/Lib/test/test_importlib/test_read.py @@ -2,15 +2,15 @@ import unittest from importlib import import_module, resources from . import data01 -from . import util +from .resources import util -class CommonBinaryTests(util.CommonResourceTests, unittest.TestCase): +class CommonBinaryTests(util.CommonTests, unittest.TestCase): def execute(self, package, path): resources.read_binary(package, path) -class CommonTextTests(util.CommonResourceTests, unittest.TestCase): +class CommonTextTests(util.CommonTests, unittest.TestCase): def execute(self, package, path): resources.read_text(package, path) @@ -55,5 +55,12 @@ class ReadZipTests(ReadTests, util.ZipSetup, unittest.TestCase): self.assertEqual(result, b'\0\1\2\3') +class ReadNamespaceTests(ReadTests, unittest.TestCase): + def setUp(self): + from . import namespacedata01 + + self.data = namespacedata01 + + if __name__ == '__main__': unittest.main() |