Work around a source compatibility break in the Swift 6 stdlib #23
Workflow file for this run
This file contains 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: Swift package tests (Apple) | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
jobs: | |
test-macos12: | |
strategy: | |
matrix: | |
xcode-version: | |
- 13.2.1 # Swift 5.5.3 | |
- 13.4.1 # Swift 5.6.3 | |
- 14.2 # Swift 5.7.2 | |
runs-on: macos-12 | |
continue-on-error: ${{ matrix.xcode-version == '13.2.1' || matrix.xcode-version == '13.4.1' }} # Package resolution can be flaky. | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Build | |
run: | | |
env DEVELOPER_DIR="/Applications/Xcode_${{ matrix.xcode-version }}.app" xcrun xcodebuild -resolvePackageDependencies -clonedSourcePackagesDirPath "$PWD/.dependencies" | |
env DEVELOPER_DIR="/Applications/Xcode_${{ matrix.xcode-version }}.app" xcrun xcodebuild -IDEClonedSourcePackagesDirPathOverride="$PWD/.dependencies" -derivedDataPath "$PWD/.derivedData-${{ matrix.xcode-version }}" -scheme "swift-url-Package" -destination "generic/platform=macos" build | |
- name: Run tests | |
run: | | |
env SWIFT_URL_REPORT_PATH="/private/var/tmp/swift-url-report/" DEVELOPER_DIR="/Applications/Xcode_${{ matrix.xcode-version }}.app" xcrun xcodebuild -IDEClonedSourcePackagesDirPathOverride="$PWD/.dependencies" -derivedDataPath "$PWD/.derivedData-${{ matrix.xcode-version }}" -scheme "swift-url-Package" -destination "platform=macos" -retry-tests-on-failure test | |
- name: Upload report files | |
uses: actions/upload-artifact@v3 | |
with: | |
name: test-reports-macos-xcode-${{ matrix.xcode-version }} | |
path: /private/var/tmp/swift-url-report/* | |
if-no-files-found: warn | |
build-only: | |
strategy: | |
matrix: | |
target-os: [macos, ios, tvos, watchos] | |
runs-on: macos-12 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Build | |
run: | | |
xcrun xcodebuild -IDEClonedSourcePackagesDirPathOverride="$PWD/.dependencies" -derivedDataPath "$PWD/.derivedData-${{ matrix.target-os }}" -scheme "swift-url-Package" -destination "generic/platform=${{ matrix.target-os }}" build | |
- name: Build benchmarks | |
if: ${{ matrix.target-os == 'macos' }} | |
run: | | |
cd Benchmarks | |
swift build -v |