Bump importlib-resources from 6.0.1 to 6.4.0 (#2285)

* Bump importlib-resources from 6.0.1 to 6.4.0

Bumps [importlib-resources](https://github.com/python/importlib_resources) from 6.0.1 to 6.4.0.
- [Release notes](https://github.com/python/importlib_resources/releases)
- [Changelog](https://github.com/python/importlib_resources/blob/main/NEWS.rst)
- [Commits](https://github.com/python/importlib_resources/compare/v6.0.1...v6.4.0)

---
updated-dependencies:
- dependency-name: importlib-resources
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* Update importlib-resources==6.4.0

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: JonnyWong16 <9099342+JonnyWong16@users.noreply.github.com>

[skip ci]
This commit is contained in:
dependabot[bot] 2024-03-24 15:27:55 -07:00 committed by GitHub
parent 6c6fa34ba4
commit b01b21ae05
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
34 changed files with 725 additions and 349 deletions

View file

@ -1,4 +1,3 @@
import typing
import textwrap
import unittest
import warnings
@ -10,7 +9,8 @@ from ..abc import Traversable
from . import data01
from . import util
from . import _path
from ._compat import os_helper, import_helper
from .compat.py39 import os_helper
from .compat.py312 import import_helper
@contextlib.contextmanager
@ -31,13 +31,14 @@ class FilesTests:
actual = files.joinpath('utf-8.file').read_text(encoding='utf-8')
assert actual == 'Hello, UTF-8 world!\n'
@unittest.skipUnless(
hasattr(typing, 'runtime_checkable'),
"Only suitable when typing supports runtime_checkable",
)
def test_traversable(self):
assert isinstance(resources.files(self.data), Traversable)
def test_joinpath_with_multiple_args(self):
files = resources.files(self.data)
binfile = files.joinpath('subdirectory', 'binary.file')
self.assertTrue(binfile.is_file())
def test_old_parameter(self):
"""
Files used to take a 'package' parameter. Make sure anyone
@ -63,13 +64,17 @@ class OpenNamespaceTests(FilesTests, unittest.TestCase):
self.data = namespacedata01
class OpenNamespaceZipTests(FilesTests, util.ZipSetup, unittest.TestCase):
ZIP_MODULE = 'namespacedata01'
class SiteDir:
def setUp(self):
self.fixtures = contextlib.ExitStack()
self.addCleanup(self.fixtures.close)
self.site_dir = self.fixtures.enter_context(os_helper.temp_dir())
self.fixtures.enter_context(import_helper.DirsOnSysPath(self.site_dir))
self.fixtures.enter_context(import_helper.CleanImport())
self.fixtures.enter_context(import_helper.isolated_modules())
class ModulesFilesTests(SiteDir, unittest.TestCase):