diff --git a/.github/workflows/native-tests.yml b/.github/workflows/native-tests.yml index 3edb1d2b..189b11b3 100644 --- a/.github/workflows/native-tests.yml +++ b/.github/workflows/native-tests.yml @@ -14,6 +14,7 @@ env: jobs: native-unit-tests: strategy: + fail-fast: false max-parallel: 4 matrix: platform: [iOS, tvOS] @@ -28,8 +29,21 @@ jobs: - name: Checkout uses: actions/checkout@v5 - - name: Select Xcode - run: sudo xcode-select -s /Applications/Xcode_${{ env.XCODE_VERSION }}.app + - name: Set up Xcode + uses: maxim-lobanov/setup-xcode@v1 + with: + xcode-version: ${{ env.XCODE_VERSION }} + + - name: Setup specified simulator + uses: futureware-tech/simulator-action@v4 + id: simulator + with: + model: ${{ matrix.device }} + os: ${{ matrix.platform }} + os_version: '>=18.0' + erase_before_boot: true + wait_for_boot: true + shutdown_after_job: true - name: Run unit tests - run: xcodebuild -project mParticle-Apple-SDK.xcodeproj -scheme ${{ matrix.scheme }} -destination 'platform=${{ matrix.platform }} Simulator,name=${{ matrix.device }},OS=latest' test + run: xcodebuild -project mParticle-Apple-SDK.xcodeproj -scheme ${{ matrix.scheme }} -destination 'id=${{ steps.simulator.outputs.UDID }}' test