From 2184639c04f9d3c5c621e9f8dbb4d8725105f696 Mon Sep 17 00:00:00 2001 From: Patrick Cronin Date: Thu, 30 Apr 2026 14:23:36 -0400 Subject: [PATCH 1/4] Build step seems flaky --- .github/workflows/ci.yml | 50 ++++++++++++++++++++++++++++++++-------- 1 file changed, 40 insertions(+), 10 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9d13292..b852fde 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,11 +40,26 @@ jobs: - name: Run Tests run: | - xcodebuild test \ - -scheme MinFraudDevice \ - -destination "${{ matrix.destination }}" \ - -resultBundlePath TestResults-iOS${{ matrix.ios-version }}.xcresult \ - | xcpretty && exit ${PIPESTATUS[0]} + attempts=3 + status=1 + for attempt in $(seq 1 $attempts); do + echo "::group::Test attempt $attempt of $attempts" + rm -rf TestResults-iOS${{ matrix.ios-version }}.xcresult + set +e + xcodebuild test \ + -scheme MinFraudDevice \ + -destination "${{ matrix.destination }}" \ + -resultBundlePath TestResults-iOS${{ matrix.ios-version }}.xcresult \ + | xcpretty + status=${PIPESTATUS[0]} + set -e + echo "::endgroup::" + if [ $status -eq 0 ]; then + exit 0 + fi + echo "Test attempt $attempt failed with exit code $status" + done + exit $status - name: Upload Test Results if: always() @@ -89,11 +104,26 @@ jobs: - name: Build Example App run: | - xcodebuild build \ - -project Example/MinFraudDeviceExample/MinFraudDeviceExample.xcodeproj \ - -scheme MinFraudDeviceExample \ - -destination "${{ matrix.destination }}" \ - | xcpretty && exit ${PIPESTATUS[0]} + attempts=3 + status=1 + for attempt in $(seq 1 $attempts); do + echo "::group::Test attempt $attempt of $attempts" + rm -rf TestResults-iOS${{ matrix.ios-version }}.xcresult + set +e + xcodebuild build \ + -project Example/MinFraudDeviceExample/MinFraudDeviceExample.xcodeproj \ + -scheme MinFraudDeviceExample \ + -destination "${{ matrix.destination }}" \ + | xcpretty && exit ${PIPESTATUS[0]} + status=${PIPESTATUS[0]} + set -e + echo "::endgroup::" + if [ $status -eq 0 ]; then + exit 0 + fi + echo "Test attempt $attempt failed with exit code $status" + done + exit $status lint: name: SwiftLint From c9beff7c6d27af8de7642f850702e0a94ab3d858 Mon Sep 17 00:00:00 2001 From: Patrick Cronin Date: Thu, 30 Apr 2026 14:26:01 -0400 Subject: [PATCH 2/4] Ensure docs use a currently-present platform name --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index c3155ea..b75ab10 100644 --- a/README.md +++ b/README.md @@ -137,7 +137,7 @@ xcodebuild build -scheme MinFraudDevice -destination 'generic/platform=iOS Simul ### Testing ```bash -xcodebuild test -scheme MinFraudDevice -destination 'platform=iOS Simulator,name=iPhone 16' +xcodebuild test -scheme MinFraudDevice -destination 'platform=iOS Simulator,name=iPhone 17' ``` ### Code Quality @@ -175,7 +175,7 @@ Build it with: xcodebuild build \ -project Example/MinFraudDeviceExample/MinFraudDeviceExample.xcodeproj \ -scheme MinFraudDeviceExample \ - -destination 'platform=iOS Simulator,name=iPhone 16' + -destination 'platform=iOS Simulator,name=iPhone 17' ``` ## Contributing From 1dbdd115119401b09c28df77c5f8fa5c6448373d Mon Sep 17 00:00:00 2001 From: Patrick Cronin Date: Thu, 30 Apr 2026 14:59:20 -0400 Subject: [PATCH 3/4] Fit currently available runner installed software --- .github/workflows/ci.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b852fde..b221f6b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,9 +19,9 @@ jobs: xcode-version: "15.4" destination: "platform=iOS Simulator,name=iPhone 15,OS=17.5" - runner-image: "macos-15" - ios-version: "18.6" + ios-version: "18.5" xcode-version: "16.4" - destination: "platform=iOS Simulator,name=iPhone 16,OS=18.6" + destination: "platform=iOS Simulator,name=iPhone 16,OS=18.5" - runner-image: "macos-26" ios-version: "26.1" xcode-version: "26.3" @@ -83,9 +83,9 @@ jobs: xcode-version: "15.4" destination: "platform=iOS Simulator,name=iPhone 15,OS=17.5" - runner-image: "macos-15" - ios-version: "18.6" + ios-version: "18.5" xcode-version: "16.4" - destination: "platform=iOS Simulator,name=iPhone 16,OS=18.6" + destination: "platform=iOS Simulator,name=iPhone 16,OS=18.5" - runner-image: "macos-26" ios-version: "26.1" xcode-version: "26.3" From fe10f64da6535d201ad86b2f8855b3888171dcbb Mon Sep 17 00:00:00 2001 From: Patrick Cronin Date: Thu, 30 Apr 2026 15:04:02 -0400 Subject: [PATCH 4/4] Run the CI checks weekly --- .github/workflows/ci.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b221f6b..fd0be04 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,6 +1,10 @@ name: CI -on: [push, pull_request] +on: + push: + pull_request: + schedule: + - cron: "0 12 * * 1" # Mondays at 12:00 UTC permissions: {}