Skip to content

Test macOS on CI #1752

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Dec 1, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Restore longer extra time for Windows, and add for macOS
This undoes the testing breakage of test_blocking_lock_file for
Windows, and gives macOS the same amount of extra time as Windows.

I had expected that macOS, even though it needs more time than
Ubuntu, might not need as much extra time as Windows. That turned
out not to be the case, in the limited testing done so far on CI.
Windows, while still slower than Ubuntu and still too slow to
reliably pass the test_blocking_lock_file test, was usually faster
than macOS and passed more often.

These relative timings may turn out not to be a trend and only to
apply to the current GHA runners. That's probably okay since the
adjustment for macOS wasn't present before and is being added to
allow newly introduced macOS CI test jobs to pass.

That is all in regard to the very specific issue of the extra time
required for the test_blocking_lock_file test after the lock, which
makes an assertion about that not taking too long. Regarding the
overall time of entire test jobs, macOS 13 seems to have usually
been a little faster than macOS 12, so it is retained. Unlike
"macos-latest", which currently is macOS 12, "macos-13" will never
refer to a later version of the operating system, so the version
given in the workflow should be revisited later, at or after the
time "macos-latest" becomes a synonym of "macos-13".
  • Loading branch information
EliahKagan committed Dec 1, 2023
commit c16e4f371b1ee193af92c4ef685315ca1d41e6e9
2 changes: 1 addition & 1 deletion test/test_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -397,7 +397,7 @@ def test_blocking_lock_file(self):
self.assertRaises(IOError, wait_lock._obtain_lock)
elapsed = time.time() - start
extra_time = 0.02
if sys.platform == "cygwin": # FIXME: Put back native Windows check.
if os.name == "nt" or sys.platform == "cygwin" or sys.platform == "darwin":
extra_time *= 6 # NOTE: Indeterministic failures without this...
self.assertLess(elapsed, wait_time + extra_time)

Expand Down