Skip to content

Commit

Permalink
ci: GitHub Actions Xcode version test matrix (#220)
Browse files Browse the repository at this point in the history
  • Loading branch information
einsteinx2 authored Aug 30, 2023
1 parent 169b997 commit d412af8
Showing 1 changed file with 20 additions and 30 deletions.
50 changes: 20 additions & 30 deletions .github/workflows/native-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,38 +9,28 @@ on:
- development

jobs:
ios-unit-tests:
runs-on: macos-latest
native-unit-tests:
strategy:
matrix:
xcode: ["14.3.1", "15.0"]
platform: [iOS, tvOS]
scheme: [mParticle-Apple-SDK, mParticle-Apple-SDK-NoLocation]
include:
- xcode: "14.3.1"
os: "16.4"
- xcode: "15.0"
os: "17.0"
- platform: iOS
device: iPhone 14
- platform: tvOS
device: Apple TV
runs-on: macos-13
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Select Xcode
run: sudo xcode-select -s /Applications/Xcode_${{ matrix.xcode }}.app

- name: Run iOS unit tests
run: xcodebuild -project mParticle-Apple-SDK.xcodeproj -scheme mParticle-Apple-SDK -destination "platform=iOS Simulator,name=iPhone 14,OS=latest" test

tvos-unit-tests:
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Run tvOS unit tests
run: xcodebuild -project mParticle-Apple-SDK.xcodeproj -scheme mParticle-Apple-SDK -destination "platform=tvOS Simulator,name=Apple TV,OS=latest" test

ios-nolocation-unit-tests:
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Run iOS unit tests
run: xcodebuild -project mParticle-Apple-SDK.xcodeproj -scheme mParticle-Apple-SDK-NoLocation -destination "platform=iOS Simulator,name=iPhone 14,OS=latest" test

tvos-nolocation-unit-tests:
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Run tvOS unit tests
run: xcodebuild -project mParticle-Apple-SDK.xcodeproj -scheme mParticle-Apple-SDK-NoLocation -destination "platform=tvOS Simulator,name=Apple TV,OS=latest" test
run: xcodebuild -project mParticle-Apple-SDK.xcodeproj -scheme ${{ matrix.scheme }} -destination 'platform=${{ matrix.platform }} Simulator,name=${{ matrix.device }},OS=${{ matrix.os }}' test

0 comments on commit d412af8

Please sign in to comment.