2. iOS Test #4
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: 2. iOS Test | |
| on: | |
| workflow_dispatch: | |
| inputs: | |
| iPhoneVersion: | |
| type: string | |
| description: iPhone version to run tests on | |
| required: false | |
| default: "15" | |
| iOSVersion: | |
| type: string | |
| description: iOS version to run tests on | |
| required: false | |
| default: "17.4" | |
| workflow_call: | |
| inputs: | |
| iPhoneVersion: | |
| type: string | |
| description: iPhone version to run tests on | |
| required: false | |
| default: "15" | |
| iOSVersion: | |
| type: string | |
| description: iOS version to run tests on | |
| required: false | |
| default: "17.4" | |
| jobs: | |
| test: | |
| runs-on: macos-14 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Set up Xcode | |
| run: | | |
| sudo xcode-select -s /Applications/Xcode.app | |
| - name: Set inputs | |
| run: | | |
| if [ -z "${{ inputs.iPhoneVersion }}" ]; then | |
| echo "iPhoneVersion=15" >> $GITHUB_ENV | |
| else | |
| echo "iPhoneVersion=${{ inputs.iPhoneVersion }}" >> $GITHUB_ENV | |
| fi | |
| if [ -z "${{ inputs.iOSVersion }}" ]; then | |
| echo "iOSVersion=17.4" >> $GITHUB_ENV | |
| else | |
| echo "iOSVersion=${{ inputs.iOSVersion }}" >> $GITHUB_ENV | |
| fi | |
| - name: Run test | |
| run: | | |
| xcodebuild test -scheme Jarvis \ | |
| -destination 'platform=iOS Simulator,name=iPhone ${{ env.iPhoneVersion }},OS=${{ env.iOSVersion }}' \ | |
| -only-testing:JarvisTests/testExample \ | |
| -configuration Debug \ | |
| EXCLUDED_ARCHS=arm64 \ | |
| -parallel-testing-enabled YES \ | |
| -derivedDataPath ./derivedData \ | |
| -skipPackageUpdates \ | |
| -dry-run \ | |
| -enableCodeCoverage NO | |
| working-directory: Jarvis |