gh-106531: Apply changes from importlib_resources 6.3.2 (#117054)

Apply changes from importlib_resources 6.3.2.
This commit is contained in:
Jason R. Coombs 2024-06-04 02:36:28 -04:00 committed by GitHub
parent 31a4fb3c74
commit 8d63c8d47b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
16 changed files with 231 additions and 146 deletions

View file

@ -24,7 +24,7 @@ class OpenTests:
target = resources.files(self.data) / 'binary.file'
with target.open('rb') as fp:
result = fp.read()
self.assertEqual(result, b'\x00\x01\x02\x03')
self.assertEqual(result, bytes(range(4)))
def test_open_text_default_encoding(self):
target = resources.files(self.data) / 'utf-8.file'
@ -81,5 +81,9 @@ class OpenZipTests(OpenTests, util.ZipSetup, unittest.TestCase):
pass
class OpenNamespaceZipTests(OpenTests, util.ZipSetup, unittest.TestCase):
ZIP_MODULE = 'namespacedata01'
if __name__ == '__main__':
unittest.main()