Aurelien Larcher
2021-01-08 b5a8497ec9558d0061024ac4b49f445bbe7d1094
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
From OmniOS
 
This test tries to set a file date to 2108-12-30.
On illumos, the os.utime() call raises:
    OSError: [Errno 79] Value too large for defined data type
 
diff -wpruN '--exclude=*.orig' a~/Lib/test/test_zipfile.py a/Lib/test/test_zipfile.py
--- a~/Lib/test/test_zipfile.py    1970-01-01 00:00:00
+++ a/Lib/test/test_zipfile.py    1970-01-01 00:00:00
@@ -616,7 +616,7 @@ class StoredTestsWithSourceFile(Abstract
             self.skipTest(f'time.localtime({ts}) raises OverflowError')
         try:
             os.utime(TESTFN, (ts, ts))
-        except OverflowError:
+        except (OverflowError, OSError):
             self.skipTest('Host fs cannot set timestamp to required value.')
 
         mtime_ns = os.stat(TESTFN).st_mtime_ns