Skip to content

chore: fix CI build for iOS tests#597

Open
ttypic wants to merge 1 commit intomainfrom
ci-fix
Open

chore: fix CI build for iOS tests#597
ttypic wants to merge 1 commit intomainfrom
ci-fix

Conversation

@ttypic
Copy link
Copy Markdown
Contributor

@ttypic ttypic commented Apr 8, 2026

iOS builds were very unreliable. After the simulator boots, the runner is barely responsive, and even the simplest tasks take minutes. To address this, we prebuild everything and start the emulator at the latest possible moment.

Summary by CodeRabbit

  • Chores
    • Updated minimum iOS deployment target to version 12.0
    • Enhanced iOS application configuration to support modern input handling and improved graphics performance
    • Modernized iOS build system settings and Xcode project configuration for improved build reliability

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 8, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 4c7dafaa-5f47-4bc2-aaab-3fb8cab28f72

📥 Commits

Reviewing files that changed from the base of the PR and between a9f78c4 and 4363552.

⛔ Files ignored due to path filters (1)
  • test_integration/ios/Podfile.lock is excluded by !**/*.lock
📒 Files selected for processing (8)
  • .github/workflows/flutter_integration.yaml
  • .github/workflows/ios_unit_tests.yml
  • test_integration/ios/Flutter/AppFrameworkInfo.plist
  • test_integration/ios/Podfile
  • test_integration/ios/Runner.xcodeproj/project.pbxproj
  • test_integration/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme
  • test_integration/ios/Runner/AppDelegate.swift
  • test_integration/ios/Runner/Info.plist
✅ Files skipped from review due to trivial changes (4)
  • test_integration/ios/Flutter/AppFrameworkInfo.plist
  • test_integration/ios/Runner/Info.plist
  • test_integration/ios/Runner.xcodeproj/project.pbxproj
  • test_integration/ios/Podfile
🚧 Files skipped from review as they are similar to previous changes (3)
  • test_integration/ios/Runner/AppDelegate.swift
  • .github/workflows/flutter_integration.yaml
  • .github/workflows/ios_unit_tests.yml

Walkthrough

CI workflows now replace third‑party simulator actions with manual xcrun simctl steps to select and boot an iPhone simulator; iOS minimum deployment targets were raised to 12.0, Xcode project/scheme metadata updated, AppDelegate entry point modernized, and two Info.plist keys added.

Changes

Cohort / File(s) Summary
CI/CD Workflow Modernization
\.github/workflows/flutter_integration.yaml, \.github/workflows/ios_unit_tests.yml
Removed futureware-tech/simulator-action; added explicit xcrun simctl device selection/UDID export to SIMULATOR_ID, simulator boot steps, and adjusted flutter build/drive and xcodebuild test destinations to use the selected UDID.
iOS Deployment Target & Podfile
test_integration/ios/Flutter/AppFrameworkInfo.plist, test_integration/ios/Podfile
Bumped minimum iOS deployment target to 12.0; moved use_frameworks! into the Runner target and added use_modular_headers!.
Xcode Project & Scheme
test_integration/ios/Runner.xcodeproj/project.pbxproj, test_integration/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme
Updated Xcode object/version metadata (objectVersion, LastUpgradeCheck), set alwaysOutOfDate = 1 on build phases, added an inputPaths entry to the Thin Binary phase, and enabled GPU validation mode in the scheme.
App Entry & Info.plist
test_integration/ios/Runner/AppDelegate.swift, test_integration/ios/Runner/Info.plist
Replaced @UIApplicationMain with @main on AppDelegate; added CADisableMinimumFrameDurationOnPhone and UIApplicationSupportsIndirectInputEvents keys to Info.plist.

Sequence Diagram(s)

sequenceDiagram
  participant GH as GitHub Actions
  participant Flutter as Flutter CLI
  participant Simctl as xcrun simctl
  participant Simulator as iOS Simulator

  GH->>Flutter: flutter pub get (root)
  GH->>Flutter: cd test_integration && flutter pub get
  GH->>Flutter: flutter build ios --simulator
  GH->>Simctl: xcrun simctl list devices available
  Simctl-->>GH: list of devices
  GH->>GH: extract first iPhone UDID -> SIMULATOR_ID
  GH->>Simctl: xcrun simctl boot $SIMULATOR_ID
  Simctl-->>Simulator: boot device id
  GH->>Flutter: cd test_integration && flutter drive --no-pub --no-build --target ... -d $SIMULATOR_ID (using prebuilt Runner.app)
  Flutter->>Simulator: run tests on $SIMULATOR_ID
  Simulator-->>GH: test results
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

🐰 Hopped into workflows, no actions to borrow,

Chose a UDID, booted a bright iPhone tomorrow.
Targets raised, Swift greets with a new name,
Xcode tuned, plist keys join the game.
Tests run—tiny rabbit cheers at the show! 🎉

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and specifically describes the main objective of the PR: fixing CI build reliability for iOS tests through workflow improvements.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch ci-fix

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions github-actions bot temporarily deployed to staging/pull/597/dartdoc April 8, 2026 17:13 Inactive
@github-actions github-actions bot temporarily deployed to staging/pull/597/features April 8, 2026 17:13 Inactive
@ttypic ttypic changed the base branch from main to release/1.2.44 April 8, 2026 17:15
@github-actions github-actions bot temporarily deployed to staging/pull/597/dartdoc April 8, 2026 17:34 Inactive
@github-actions github-actions bot temporarily deployed to staging/pull/597/features April 8, 2026 17:34 Inactive
@github-actions github-actions bot temporarily deployed to staging/pull/597/features April 8, 2026 17:40 Inactive
@github-actions github-actions bot temporarily deployed to staging/pull/597/dartdoc April 8, 2026 17:40 Inactive
@github-actions github-actions bot temporarily deployed to staging/pull/597/features April 8, 2026 17:45 Inactive
@github-actions github-actions bot temporarily deployed to staging/pull/597/dartdoc April 8, 2026 17:45 Inactive
@github-actions github-actions bot temporarily deployed to staging/pull/597/features April 8, 2026 17:57 Inactive
@github-actions github-actions bot temporarily deployed to staging/pull/597/dartdoc April 8, 2026 17:57 Inactive
@ttypic ttypic requested a review from maratal April 8, 2026 18:05
@ttypic ttypic marked this pull request as ready for review April 8, 2026 18:06
Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
.github/workflows/flutter_integration.yaml (1)

46-52: Quote the $SIMULATOR_ID variable for defensive shell scripting.

While simulator UUIDs won't contain spaces, quoting variables is a shell best practice to prevent word splitting issues.

Suggested fix
          flutter drive --no-pub --no-build \
            --use-application-binary=build/ios/iphonesimulator/Runner.app \
-           -d $SIMULATOR_ID
+           -d "$SIMULATOR_ID"
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.github/workflows/flutter_integration.yaml around lines 46 - 52, Quote the
$SIMULATOR_ID variable in the flutter drive invocation to prevent word-splitting
in shell execution: update the Run integration tests step where the command
calls flutter drive -d $SIMULATOR_ID (in the GitHub Actions job) to use quoted
variable expansion ("$SIMULATOR_ID") so the working-directory/test_integration
run step passes a safely quoted simulator identifier to the flutter drive
command.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@test_integration/ios/Podfile`:
- Line 2: The Podfile sets platform :ios, '12.0' but the Xcode project still has
IPHONEOS_DEPLOYMENT_TARGET = 10.0 in its build configurations; update the Xcode
project.pbxproj build settings for Debug, Release and Profile to
IPHONEOS_DEPLOYMENT_TARGET = 12.0 so the project and Podfile match. Locate the
IPHONEOS_DEPLOYMENT_TARGET entries in project.pbxproj (search for
IPHONEOS_DEPLOYMENT_TARGET) and change their values to 12.0, then re-open the
workspace and verify the deployment target in Xcode’s project settings matches
the Podfile platform declaration.

---

Nitpick comments:
In @.github/workflows/flutter_integration.yaml:
- Around line 46-52: Quote the $SIMULATOR_ID variable in the flutter drive
invocation to prevent word-splitting in shell execution: update the Run
integration tests step where the command calls flutter drive -d $SIMULATOR_ID
(in the GitHub Actions job) to use quoted variable expansion ("$SIMULATOR_ID")
so the working-directory/test_integration run step passes a safely quoted
simulator identifier to the flutter drive command.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 76dbbb92-4a88-4b51-8fd2-7f2082dcfb0b

📥 Commits

Reviewing files that changed from the base of the PR and between e9168b2 and a9f78c4.

⛔ Files ignored due to path filters (1)
  • test_integration/ios/Podfile.lock is excluded by !**/*.lock
📒 Files selected for processing (8)
  • .github/workflows/flutter_integration.yaml
  • .github/workflows/ios_unit_tests.yml
  • test_integration/ios/Flutter/AppFrameworkInfo.plist
  • test_integration/ios/Podfile
  • test_integration/ios/Runner.xcodeproj/project.pbxproj
  • test_integration/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme
  • test_integration/ios/Runner/AppDelegate.swift
  • test_integration/ios/Runner/Info.plist

Base automatically changed from release/1.2.44 to main April 9, 2026 12:33
Copy link
Copy Markdown
Collaborator

@maratal maratal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants