Skip to content

Build

Build #686

Workflow file for this run

name: Build
on:
pull_request:
types:
- opened
- synchronize
- reopened
- ready_for_review
workflow_dispatch:
env:
RUST_TARGET_PATH: pact-reference
jobs:
test:
name: Run ${{ matrix.platform }} on ${{ matrix.host }}
runs-on: ${{ matrix.host }}
strategy:
fail-fast: true
matrix:
host: [macos-13, macos-14]
platform: [ios, macos]
include:
- platform: ios
scheme: "PactSwift-iOS"
destination: "platform=iOS Simulator,name=iPhone 15 Pro"
- platform: macos
scheme: "PactSwift-macOS"
destination: "arch=x86_64"
- host: macos-13
xcode: 14.3.1
- host: macos-14
xcode: 15.3
env:
SCHEME: ${{ matrix.scheme }}
DESTINATION: ${{ matrix.destination }}
concurrency:
group: test_${{ matrix.host }}_${{ matrix.scheme }}_${{ github.ref }}
cancel-in-progress: true
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Use Xcode ${{ matrix.xcode }}
run: sudo xcode-select -switch /Applications/Xcode_${{ matrix.xcode }}.app
- name: Prepare Tools
run: |
Scripts/prepare_build_tools
- name: Run tests (Xcode)
run: |
set -o pipefail && xcodebuild clean test -project PactSwift.xcodeproj -scheme "$SCHEME" -destination "$DESTINATION" GCC_INSTRUMENT_PROGRAM_FLOW_ARCS=YES GCC_GENERATE_TEST_COVERAGE_FILES=YES | xcbeautify
- name: Run tests (CLI - Swift Package)
run: |
swift build
swift test -c release