Fix date + Add CI Tests #58
Workflow file for this run
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: Pull Request Build | |
on: | |
pull_request: | |
branches: | |
- main | |
jobs: | |
build: | |
runs-on: macos-14 | |
strategy: | |
matrix: | |
xcode-version: [15.4, 16.1] | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Xcode select ${{ matrix.xcode-version }} | |
run: sudo xcode-select -s '/Applications/Xcode_${{ matrix.xcode-version }}.app/Contents/Developer' | |
- name: Get Swift Version | |
run: | | |
SWIFT_MAJOR_VERSION=$(swift --version 2>&1 | awk '/Apple Swift version/ { split($7, ver, "."); print ver[1]; exit }') | |
echo "Swift major version: $SWIFT_MAJOR_VERSION" | |
echo "SWIFT_VERSION=$SWIFT_MAJOR_VERSION.0" >> "$GITHUB_ENV" | |
- name: Build for iOS Simulator | |
run: xcodebuild build -scheme ETDistribution -sdk iphonesimulator -destination 'generic/platform=iOS Simulator' SWIFT_TREAT_WARNINGS_AS_ERRORS=YES GCC_TREAT_WARNINGS_AS_ERRORS=YES | |
- name: Build for iOS | |
run: xcodebuild build -scheme ETDistribution -sdk iphoneos -destination 'generic/platform=iOS' SWIFT_TREAT_WARNINGS_AS_ERRORS=YES GCC_TREAT_WARNINGS_AS_ERRORS=YES | |
- name: Build TestApp | |
run: cd Example && xcodebuild build -scheme DemoApp -sdk iphonesimulator -destination 'generic/platform=iOS Simulator' -project DemoApp.xcodeproj SWIFT_VERSION=${{ env.SWIFT_VERSION }} |