Skip to content

Commit

Permalink
gh-123994: Generate utf-16 file using little endian and BOM. (#123995)
Browse files Browse the repository at this point in the history
  • Loading branch information
jaraco committed Sep 12, 2024
1 parent c00a2b7 commit 313bed2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions importlib_resources/tests/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ def test_useless_loader(self):
data01={
'__init__.py': '',
'binary.file': bytes(range(4)),
'utf-16.file': 'Hello, UTF-16 world!\n'.encode('utf-16'),
'utf-16.file': '\ufeffHello, UTF-16 world!\n'.encode('utf-16-le'),
'utf-8.file': 'Hello, UTF-8 world!\n'.encode('utf-8'),
'subdirectory': {
'__init__.py': '',
Expand All @@ -160,7 +160,7 @@ def test_useless_loader(self):
},
namespacedata01={
'binary.file': bytes(range(4)),
'utf-16.file': 'Hello, UTF-16 world!\n'.encode('utf-16'),
'utf-16.file': '\ufeffHello, UTF-16 world!\n'.encode('utf-16-le'),
'utf-8.file': 'Hello, UTF-8 world!\n'.encode('utf-8'),
'subdirectory': {
'binary.file': bytes(range(12, 16)),
Expand Down

0 comments on commit 313bed2

Please sign in to comment.