Add Graph::trace_assertion_failure and fix duplicate error_message sy… #732
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: iOS | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| jobs: | |
| ios_test: | |
| name: Execute tests on iOS | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [macos-15] | |
| xcode-version: ["16.4"] # Swift 6.1.2 | |
| ios-version: ["18.5"] | |
| include: | |
| - ios-version: "18.5" | |
| ios-simulator-name: "iPhone 16 Pro" | |
| runs-on: ${{ matrix.os }} | |
| env: | |
| OPENATTRIBUTEGRAPH_WERROR: 1 | |
| OPENATTRIBUTEGRAPH_USE_LOCAL_DEPS: 1 | |
| OPENATTRIBUTEGRAPH_TARGET_RELEASE: 2024 | |
| DARWINPRIVATEFRAMEWORKS_TARGET_RELEASE: 2024 | |
| GH_TOKEN: ${{ github.token }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| submodules: true | |
| - name: Setup Xcode | |
| uses: OpenSwiftUIProject/OpenSwiftUI/.github/actions/setup-xcode@main | |
| with: | |
| xcode-version: ${{ matrix.xcode-version }} | |
| - name: Set up build environment | |
| run: Scripts/CI/darwin_setup_build.sh | |
| shell: bash | |
| - name: Build in debug mode on iOS | |
| run: | | |
| xcodebuild build \ | |
| -workspace .swiftpm/xcode/package.xcworkspace \ | |
| -scheme OpenAttributeGraph-Package \ | |
| -configuration Debug \ | |
| -destination "platform=iOS Simulator,OS=${{ matrix.ios-version }},name=${{ matrix.ios-simulator-name }}" \ | |
| -derivedDataPath .build-debug \ | |
| -skipMacroValidation \ | |
| -skipPackagePluginValidation \ | |
| OTHER_SWIFT_FLAGS="-warnings-as-errors" | |
| - name: Build and run tests in debug mode with coverage on iOS Simulator | |
| run: | | |
| xcodebuild test \ | |
| -workspace .swiftpm/xcode/package.xcworkspace \ | |
| -scheme OpenAttributeGraph-Package \ | |
| -configuration Debug \ | |
| -destination "platform=iOS Simulator,OS=${{ matrix.ios-version }},name=${{ matrix.ios-simulator-name }}" \ | |
| -enableCodeCoverage=YES \ | |
| -derivedDataPath .build-test-debug \ | |
| -skipPackagePluginValidation \ | |
| -skipMacroValidation | |
| # OTHER_SWIFT_FLAGS="-warnings-as-errors" Conflicting options '-warnings-as-errors' and '-suppress-warnings' | |
| - name: Generate iOS coverage report | |
| run: | | |
| # Extract profdata and binary from xcodebuild's derived data to generate | |
| # llvm-cov text output (same format as macOS/Ubuntu workflows). | |
| # Note: swift_project param in codecov-action doesn't auto-discover xcodebuild coverage, | |
| # and xcrun xccov JSON format isn't recognized by Codecov's parser. | |
| PROFDATA=$(find .build-test-debug -name "Coverage.profdata" -type f | head -1) | |
| XCTEST=$(find .build-test-debug -name "*.xctest" -type d | head -1) | |
| if [ -n "$PROFDATA" ] && [ -n "$XCTEST" ]; then | |
| BINARY="$XCTEST/$(basename "$XCTEST" .xctest)" | |
| xcrun llvm-cov show -instr-profile="$PROFDATA" "$BINARY" > coverage.txt | |
| fi | |
| - name: Upload coverage to Codecov | |
| uses: codecov/codecov-action@v5 | |
| with: | |
| token: ${{ secrets.CODECOV_TOKEN }} | |
| flags: ios | |
| verbose: true |