Skip to content

Conversation

@rnro
Copy link
Contributor

@rnro rnro commented Mar 12, 2025

Enable macOS CI

Motivation:

To expand test coverage to the Darwin platforms.

Modifications:

Create a new re-usable workflow macos_tests.yml which offers testing and compilation checks for multiple Xcodes and simulator destinations.

The new workflow first performs swift test with configurable parameters and then goes on to build the code targeting generic destinations for:

  • iOS
  • macOS
  • macOS Catalyst
  • tvOS
  • visionOS (temporarily disabled due to a possible runner issue)
  • watchOS

At the moment this is workflow is enabled to run on the NIO repository:

  • on each commit to a PR
  • on each merge to main
  • overnight on a timer

This will likely be revised due to capacity.

This functionality is implemented as a standalone workflow to preserve flexibility as requirements and capacity change over time.

Result:

Increased test coverage.

@rnro rnro force-pushed the macos_ci branch 3 times, most recently from ff2b48e to 1825667 Compare March 12, 2025 09:46
@rnro rnro added the semver/none No version bump required. label Mar 12, 2025
@rnro
Copy link
Contributor Author

rnro commented Mar 12, 2025

I will remove the test shim commit (9fc64f2) prior to merging - it's there to show the workflow in operation.

@rnro rnro marked this pull request as ready for review March 12, 2025 09:50
rnro added 3 commits March 12, 2025 10:01
Motivation:

To expand test coverage to the Darwin platforms.

Modifications:

Create a new re-usable workflow 'macos_tests.yml' which offers testing
and compilation checks for multiple Xcodes and simulator destinations.

The new workflow first performs `swift test` with configurable
parameters and then goes on to build the code targetting generic targets
for:
* macOS
* iOS
* watchOS
* tvOS
* visionOS

At the moment this is workflow is enabled to run on the NIO repository:
* on each commit to a PR
* on each merge to `main`
* overnight on a timer

This will likely be revised due to capacity.

Result:

Increased test coverage.
@@ -0,0 +1,157 @@
name: macOS tests
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we provide a separate workflow for this instead of inside the existing testing workflow? We can disable it by default there but in the end all of our projects want to test on macOS and it would be easier to roll it out wide without requiring a new workflow. Maybe I'm missing something though.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried to give a nod to this in the description but perhaps more detail is needed:

This functionality is implemented as a standalone workflow to preserve flexibility as requirements and capacity change over time.

The pattern of use (on PRs?, run nightly?), requirements, and node capacity are likely to be in flux over the short term as more repositories are onboarded and we understand load - I wanted to reserve as much flexibility as possible. I agree in an ideal world they'd be one matrix.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The actual task(s) we're performing here is also very different, we want to run a bunch of checks on one node to avoid the recycle time, not just swift test.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense. Thanks for expanding

@rnro rnro enabled auto-merge (squash) March 12, 2025 15:46
@rnro rnro merged commit f2f36af into main Mar 12, 2025
80 checks passed
@rnro rnro deleted the macos_ci branch March 12, 2025 20:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

semver/none No version bump required.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants