diff options
author | Ayappan Perumal <ayappap2@in.ibm.com> | 2024-02-01 11:52:54 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-02-01 11:52:54 (GMT) |
commit | 4dbb198d279a06fed74ea4c38f93d658baf38170 (patch) | |
tree | 0e4f2aad5c88bafa5dcd4bf5839437a6aa0b0ef1 | |
parent | 0bf42dae7e73febc76ea96fd58af6b765a12b8a7 (diff) | |
download | cpython-4dbb198d279a06fed74ea4c38f93d658baf38170.zip cpython-4dbb198d279a06fed74ea4c38f93d658baf38170.tar.gz cpython-4dbb198d279a06fed74ea4c38f93d658baf38170.tar.bz2 |
gh-105089: Fix test_create_directory_with_write test failure in AIX (GH-105228)
-rw-r--r-- | Lib/test/test_zipfile/test_core.py | 2 | ||||
-rw-r--r-- | Misc/NEWS.d/next/Tests/2023-06-02-05-04-15.gh-issue-105089.KaZFtU.rst | 4 |
2 files changed, 5 insertions, 1 deletions
diff --git a/Lib/test/test_zipfile/test_core.py b/Lib/test/test_zipfile/test_core.py index 9bdb08a..a177044 100644 --- a/Lib/test/test_zipfile/test_core.py +++ b/Lib/test/test_zipfile/test_core.py @@ -2959,7 +2959,7 @@ class TestWithDirectory(unittest.TestCase): directory = os.path.join(TESTFN2, "directory2") os.mkdir(directory) - mode = os.stat(directory).st_mode + mode = os.stat(directory).st_mode & 0xFFFF zf.write(directory, arcname="directory2/") zinfo = zf.filelist[1] self.assertEqual(zinfo.filename, "directory2/") diff --git a/Misc/NEWS.d/next/Tests/2023-06-02-05-04-15.gh-issue-105089.KaZFtU.rst b/Misc/NEWS.d/next/Tests/2023-06-02-05-04-15.gh-issue-105089.KaZFtU.rst new file mode 100644 index 0000000..d04ef43 --- /dev/null +++ b/Misc/NEWS.d/next/Tests/2023-06-02-05-04-15.gh-issue-105089.KaZFtU.rst @@ -0,0 +1,4 @@ +Fix +``test.test_zipfile.test_core.TestWithDirectory.test_create_directory_with_write`` +test in AIX by doing a bitwise AND of 0xFFFF on mode , so that it will be in +sync with ``zinfo.external_attr`` |