Skip to content

Migrate ios driver tests batch 2 to simulators - #190930

Merged
auto-submit[bot] merged 7 commits into
flutter:masterfrom
okorohelijah:migrate_ios_driver_tests_batch_2
Aug 28, 2026
Merged

auto-submit[bot] merged 7 commits into
flutter:masterfrom
okorohelijah:migrate_ios_driver_tests_batch_2

Conversation

@okorohelijah

@okorohelijah okorohelijah commented Aug 11, 2026 •

Copy link
Copy Markdown
Contributor

Part of #186414

This batch migrates 3 Devicelab tests to the simulator and deletes 1 obsolete driver test:

  • channels_integration_test_ios
  • platform_interaction_test_ios
  • ios_platform_view_tests (Deleted)
  • route_test_ios

Changes:

  • Moved targets from Mac_ios to Mac (Simulator) with bringup: true and injected ruby dependency.
  • Changed tags to hostonly.
  • Wrapped Devicelab tasks with testWithNewIOSSimulator.
  • Migrated platform_interaction, and ui integration test apps to use UIScene lifecycle
  • Skipped channels_integration_test_ios AppDelegate migration intentionally, as it exists to test backwards compatibility.

Updates based on triage review:

  • Deleted the ios_platform_view_tests driver test entirely (task, CI config, and driver script) because the engine thread-merge architecture it tested is no longer present.
  • Cleaned the dev/integration_tests/ios_platform_view_tests project app by removing flutter_driver dependencies and deprecated thread-merge UI buttons. Note: The project itself is kept as it is still used by the physical device native_platform_view_ui_tests_ios XCUITest runner.

- Move channels_integration_test_ios, platform_interaction_test_ios, ios_platform_view_tests, route_test_ios from Mac_ios to Mac
- Use testWithNewIOSSimulator to run them in simulator
- Add bringup: true
- Migrate AppDelegate to UIScene lifecycle for tests
@github-actions github-actions Bot added f: routes Navigator, Router, and related APIs. team-ios Owned by iOS platform team labels Aug 11, 2026
@okorohelijah
okorohelijah marked this pull request as ready for review August 11, 2026 17:13
@okorohelijah
okorohelijah requested a review from a team as a code owner August 11, 2026 17:13

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request updates several iOS devicelab integration tests to run on a newly created iOS simulator using testWithNewIOSSimulator, configures their CI targets, and updates the iOS app delegates to support implicit Flutter engines. The feedback highlights a critical issue across all updated test files where a redundant try-finally block attempts to remove the simulator a second time, which will cause double-deletion failures during cleanup.

Comment thread dev/devicelab/bin/tasks/channels_integration_test_ios.dart
Comment thread dev/devicelab/bin/tasks/ios_platform_view_tests.dart Outdated
Comment thread dev/devicelab/bin/tasks/platform_interaction_test_ios.dart
Comment thread dev/devicelab/bin/tasks/route_test_ios.dart
@okorohelijah

okorohelijah commented Aug 11, 2026 •

Copy link
Copy Markdown
Contributor Author

This PR migrates another batch of devicelab driver tests from physical iOS devices to macOS Simulators (hostonly bots).

What these tests do:

  • channels_integration_test_ios: Verifies basic MethodChannel and BasicMessageChannel communication payloads between Dart and the native iOS host.
  • platform_interaction_test_ios: Verifies simple cross-platform tap interactions.
  • ios_platform_view_tests: Tests the rendering and lifecycle of UiKitView embedding (Platform Views) inside the Flutter view hierarchy.
  • route_test_ios: Verifies that the flutter drive --route command line flag correctly pushes an initial route to the app on boot.

Why it is safe to migrate:
None of these tests require physical iOS hardware. They test engine-to-platform communication (channels and platform views) and CLI flag parsing, which function identically on the macOS iOS Simulator. The simulator uses the exact same Darwin kernel and UIView architecture needed to validate UiKitView logic. Moving these to simulators is safe.

(Note: The AppDelegate and Info.plist for platform_interaction and ios_platform_view_tests were updated to support the UIScene lifecycle. channels_integration_test_ios was intentionally left on the legacy lifecycle to preserve its backwards-compatibility coverage).

Comment thread dev/devicelab/bin/tasks/ios_platform_view_tests.dart Outdated
@cbracken
cbracken self-requested a review August 13, 2026 21:58

@cbracken cbracken left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Is the goal here to reduce the load on physical devices to free up resources? Platform views is a case where real devices are kind of useful (see my reply to @vashworth inline).

It's not the end of the world so long as there are no benchmarks, but platform views are a case where real hardware is handy.

@vashworth

Copy link
Copy Markdown
Contributor

Is the goal here to reduce the load on physical devices to free up resources? Platform views is a case where real devices are kind of useful (see my reply to @vashworth inline).

It's not the end of the world so long as there are no benchmarks, but platform views are a case where real hardware is handy.

Yes, the goal is to free up physical device resources. However, we just focusing on migrating tests that don't really require a physical device. If the platform view tests are more reliable on a physical device, we should keep them on a physical device.

@okorohelijah

okorohelijah commented Aug 19, 2026 •

Copy link
Copy Markdown
Contributor Author

@vashworth @cbracken Since ios_platform_view_tests is a functional test (verifying that dynamically adding/removing platform views does not crash) rather than a performance benchmark, its functional threading and UIKit hierarchy behavior run consistently on the simulator.

However, given Chris's point about physical hardware acting as a canary for low-memory OOMs and driver-level edge cases:

  • If we want to be conservative and preserve physical device coverage for platform view regressions, I'm happy to remove ios_platform_view_tests from this PR and leave it on physical hardware (Mac_ios).
  • Otherwise, if freeing up the physical device pool takes priority for this non-benchmark test, it is passing cleanly on the simulator and would consistently match the physical devices.

Lmk what you prefer

@vashworth

Copy link
Copy Markdown
Contributor

Update: From triage, we decided to remove ios_platform_view_tests driver test since it's no longer needed. Note that the project should be kept because ios_platform_view_tests UI Tests are still being run.

@hellohuanlin

Copy link
Copy Markdown
Contributor

Also note that in this list, the merge-thread-related tests should be removed:

key: const ValueKey<String>('platform_view_button'),
child: const Text('show platform view'),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute<MergeThreadTestPage>(
builder: (BuildContext context) => const MergeThreadTestPage(),
),
);
},
),
// Push this button to perform an animation, which ensure the threads are unmerged after the animation.
ElevatedButton(
key: const ValueKey<String>('unmerge_button'),
child: const Text('Tap to unmerge threads'),
onPressed: () {},
),
TextButton(
key: const ValueKey<String>('platform_view_focus_test'),
child: const Text('platform view focus test'),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute<FocusTestPage>(
builder: (BuildContext context) => const FocusTestPage(),
),
);
},
),
TextButton(
key: const ValueKey<String>('platform_view_z_order_test'),
child: const Text('platform view z order test'),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute<ZOrderTestPage>(
builder: (BuildContext context) => const ZOrderTestPage(),
),
);
},
),
TextButton(
key: const ValueKey<String>('web_view_behind_context_menu_test'),
child: const Text('web view behind context menu test'),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute<WebViewBehindContextMenuTestPage>(
builder: (BuildContext context) => const WebViewBehindContextMenuTestPage(),
),
);
},
),
TextButton(
key: const ValueKey<String>('drawing_web_view_behind_context_menu_test'),
child: const Text('drawing web view behind context menu test'),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute<DrawingWebViewBehindContextMenuTestPage>(
builder: (BuildContext context) =>
const DrawingWebViewBehindContextMenuTestPage(),
),
);
},
),
TextButton(
key: const ValueKey<String>('admob_banner_in_scrollable_list_test'),
child: const Text('admob banner in scrollable list test'),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute<AdMobBannerInScrollableListTestPage>(
builder: (BuildContext context) => const AdMobBannerInScrollableListTestPage(),
),
);
},
),
],
),
);

…r_tests_batch_2

# Conflicts:
#	dev/integration_tests/ios_platform_view_tests/ios/Runner/AppDelegate.m
#	dev/integration_tests/ios_platform_view_tests/ios/Runner/Info.plist
@okorohelijah okorohelijah added the CICD Run CI/CD label Aug 25, 2026
@okorohelijah okorohelijah added the autosubmit Merge PR when tree becomes green via auto submit App label Aug 27, 2026
@auto-submit
auto-submit Bot added this pull request to the merge queue Aug 27, 2026
Merged via the queue into flutter:master with commit 22a71c3 Aug 28, 2026
23 checks passed
@flutter-dashboard flutter-dashboard Bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Aug 28, 2026
auto-submit Bot pushed a commit to flutter/packages that referenced this pull request Aug 28, 2026
flutter/flutter@e8dca90...8d8c1aa

2026-08-28 [email protected] Roll Packages from bd3cbc1 to cd4cdd0 (15 revisions) (flutter/flutter#191965)
2026-08-28 [email protected] Bump customer testing version to pick up forui tests (flutter/flutter#191931)
2026-08-28 [email protected] Use leading scroll offset instead of infinite offset to reveal pinned slivers (flutter/flutter#191329)
2026-08-28 [email protected] Roll Skia from 21f71051e749 to fe0b9a5261f9 (1 revision) (flutter/flutter#191960)
2026-08-28 [email protected] Share the common Linux window controller code in mixins (flutter/flutter#191930)
2026-08-28 [email protected] Roll Dart SDK from 2cf2f69fd9f0 to ae63a6eca3f1 (1 revision) (flutter/flutter#191953)
2026-08-28 [email protected] Roll Skia from 11e3a7cb0fd0 to 21f71051e749 (3 revisions) (flutter/flutter#191942)
2026-08-28 [email protected] Roll Dart SDK from e030e77d5413 to 2cf2f69fd9f0 (2 revisions) (flutter/flutter#191934)
2026-08-28 [email protected] Remove no-shuffle in flutter tools overall experience test (flutter/flutter#191861)
2026-08-28 [email protected] [flutter_tools] Gracefully handle Windows Application Control and security policy execution blocks (flutter/flutter#191912)
2026-08-28 [email protected] [tool] Migrate ConfigCommand to modular dependency injection (flutter/flutter#190743)
2026-08-28 [email protected] Roll Skia from 37459da0a755 to 11e3a7cb0fd0 (9 revisions) (flutter/flutter#191929)
2026-08-28 [email protected] Connect to moved-to-rect after the window is realized (flutter/flutter#191773)
2026-08-28 [email protected] macOS: Compare accessibility strings as NSStrings in tests (flutter/flutter#191853)
2026-08-28 [email protected] macOS: Record test accessibility notifications in a dictionary (flutter/flutter#191854)
2026-08-28 [email protected] Roll Fuchsia Test Scripts from 6SXRz6wsA2Zm_rAqP... to u_fSMsPU22VvUsvSo... (flutter/flutter#191927)
2026-08-28 [email protected] Roll Dart SDK from cb4c39d067f3 to e030e77d5413 (3 revisions) (flutter/flutter#191923)
2026-08-27 [email protected] Migrate ios driver tests batch 2 to simulators (flutter/flutter#190930)
2026-08-27 [email protected] [flutter_test] Ensure LiveTestWidgetsFlutterBinding executes frame and pointer callbacks in the test zone (flutter/flutter#191595)
2026-08-27 [email protected] Deprecate legacy gen_defaults tool (flutter/flutter#191911)
2026-08-27 [email protected] Fix black window in the subsurface view renderer (flutter/flutter#191850)
2026-08-27 [email protected] Roll Skia from 82e972ea84b1 to 37459da0a755 (10 revisions) (flutter/flutter#191906)
2026-08-27 [email protected] iOS: Key the platform view factory registries by NSString (flutter/flutter#191855)
2026-08-27 [email protected] Sync CHANGELOG.md from stable (flutter/flutter#191895)
2026-08-27 [email protected] [flutter_tools] Honor configured build-dir across flutter project and build targets (flutter/flutter#191592)
2026-08-27 [email protected] Revert: Handle linear and radial gradients in UberSDF (flutter/flutter#191913)
2026-08-27 [email protected] Explicitly disable HCPP in hybrid_android_views integration test (flutter/flutter#191894)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages
Please CC [email protected],[email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
pull Bot pushed a commit to jinzaizhichi/flutter that referenced this pull request Sep 3, 2026
Remove bringup for flutter#190930

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [AI contribution guidelines] and understand my
responsibilities, or I am not using AI tools.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide], including [Features
we expect every widget to implement].
- [x] I signed the [CLA].
- [ ] I listed at least one issue that this PR fixes in the description
above.
- [ ] I updated/added relevant in-code documentation (doc comments with
`///`).
- [ ] If this PR introduces a new feature or capability, I created and
linked a website documentation issue or PR in [flutter/website] (or
verified none is needed).
- [ ] I added new tests to check the change I am making, or this PR is
[test-exempt].
- [ ] I followed the [breaking change policy] and added [Data Driven
Fixes] where supported.
- [x] All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel
on [Discord].

If this change needs to override an active code freeze, provide a
comment explaining why. The code freeze workflow can be overridden by
code reviewers. See pinned issues for any active code freezes with
guidance.

**Note**: The Flutter team is currently trialing the use of [Gemini Code
Assist for
GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code).
Comments from the `gemini-code-assist` bot should not be taken as
authoritative feedback from the Flutter team. If you find its comments
useful you can update your code accordingly, but if you are unsure or
disagree with the feedback, please feel free to wait for a Flutter team
member's review for guidance on which automated comments should be
addressed.

<!-- Links -->
[Contributor Guide]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#overview
[AI contribution guidelines]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#ai-contribution-guidelines
[Tree Hygiene]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md
[test-exempt]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#tests
[Flutter Style Guide]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md
[Features we expect every widget to implement]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md#features-we-expect-every-widget-to-implement
[CLA]: https://cla.developers.google.com/
[flutter/tests]: https://github.com/flutter/tests
[flutter/website]: https://github.com/flutter/website
[breaking change policy]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#handling-breaking-changes
[Discord]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Chat.md
[Data Driven Fixes]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Data-driven-Fixes.md
victorsanni pushed a commit to victorsanni/packages that referenced this pull request Sep 9, 2026
…r#12679)

flutter/flutter@e8dca90...8d8c1aa

2026-08-28 [email protected] Roll Packages from bd3cbc1 to cd4cdd0 (15 revisions) (flutter/flutter#191965)
2026-08-28 [email protected] Bump customer testing version to pick up forui tests (flutter/flutter#191931)
2026-08-28 [email protected] Use leading scroll offset instead of infinite offset to reveal pinned slivers (flutter/flutter#191329)
2026-08-28 [email protected] Roll Skia from 21f71051e749 to fe0b9a5261f9 (1 revision) (flutter/flutter#191960)
2026-08-28 [email protected] Share the common Linux window controller code in mixins (flutter/flutter#191930)
2026-08-28 [email protected] Roll Dart SDK from 2cf2f69fd9f0 to ae63a6eca3f1 (1 revision) (flutter/flutter#191953)
2026-08-28 [email protected] Roll Skia from 11e3a7cb0fd0 to 21f71051e749 (3 revisions) (flutter/flutter#191942)
2026-08-28 [email protected] Roll Dart SDK from e030e77d5413 to 2cf2f69fd9f0 (2 revisions) (flutter/flutter#191934)
2026-08-28 [email protected] Remove no-shuffle in flutter tools overall experience test (flutter/flutter#191861)
2026-08-28 [email protected] [flutter_tools] Gracefully handle Windows Application Control and security policy execution blocks (flutter/flutter#191912)
2026-08-28 [email protected] [tool] Migrate ConfigCommand to modular dependency injection (flutter/flutter#190743)
2026-08-28 [email protected] Roll Skia from 37459da0a755 to 11e3a7cb0fd0 (9 revisions) (flutter/flutter#191929)
2026-08-28 [email protected] Connect to moved-to-rect after the window is realized (flutter/flutter#191773)
2026-08-28 [email protected] macOS: Compare accessibility strings as NSStrings in tests (flutter/flutter#191853)
2026-08-28 [email protected] macOS: Record test accessibility notifications in a dictionary (flutter/flutter#191854)
2026-08-28 [email protected] Roll Fuchsia Test Scripts from 6SXRz6wsA2Zm_rAqP... to u_fSMsPU22VvUsvSo... (flutter/flutter#191927)
2026-08-28 [email protected] Roll Dart SDK from cb4c39d067f3 to e030e77d5413 (3 revisions) (flutter/flutter#191923)
2026-08-27 [email protected] Migrate ios driver tests batch 2 to simulators (flutter/flutter#190930)
2026-08-27 [email protected] [flutter_test] Ensure LiveTestWidgetsFlutterBinding executes frame and pointer callbacks in the test zone (flutter/flutter#191595)
2026-08-27 [email protected] Deprecate legacy gen_defaults tool (flutter/flutter#191911)
2026-08-27 [email protected] Fix black window in the subsurface view renderer (flutter/flutter#191850)
2026-08-27 [email protected] Roll Skia from 82e972ea84b1 to 37459da0a755 (10 revisions) (flutter/flutter#191906)
2026-08-27 [email protected] iOS: Key the platform view factory registries by NSString (flutter/flutter#191855)
2026-08-27 [email protected] Sync CHANGELOG.md from stable (flutter/flutter#191895)
2026-08-27 [email protected] [flutter_tools] Honor configured build-dir across flutter project and build targets (flutter/flutter#191592)
2026-08-27 [email protected] Revert: Handle linear and radial gradients in UberSDF (flutter/flutter#191913)
2026-08-27 [email protected] Explicitly disable HCPP in hybrid_android_views integration test (flutter/flutter#191894)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages
Please CC [email protected],[email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
victorsanni pushed a commit to victorsanni/packages that referenced this pull request Sep 9, 2026
…r#12679)

flutter/flutter@e8dca90...8d8c1aa

2026-08-28 [email protected] Roll Packages from bd3cbc1 to cd4cdd0 (15 revisions) (flutter/flutter#191965)
2026-08-28 [email protected] Bump customer testing version to pick up forui tests (flutter/flutter#191931)
2026-08-28 [email protected] Use leading scroll offset instead of infinite offset to reveal pinned slivers (flutter/flutter#191329)
2026-08-28 [email protected] Roll Skia from 21f71051e749 to fe0b9a5261f9 (1 revision) (flutter/flutter#191960)
2026-08-28 [email protected] Share the common Linux window controller code in mixins (flutter/flutter#191930)
2026-08-28 [email protected] Roll Dart SDK from 2cf2f69fd9f0 to ae63a6eca3f1 (1 revision) (flutter/flutter#191953)
2026-08-28 [email protected] Roll Skia from 11e3a7cb0fd0 to 21f71051e749 (3 revisions) (flutter/flutter#191942)
2026-08-28 [email protected] Roll Dart SDK from e030e77d5413 to 2cf2f69fd9f0 (2 revisions) (flutter/flutter#191934)
2026-08-28 [email protected] Remove no-shuffle in flutter tools overall experience test (flutter/flutter#191861)
2026-08-28 [email protected] [flutter_tools] Gracefully handle Windows Application Control and security policy execution blocks (flutter/flutter#191912)
2026-08-28 [email protected] [tool] Migrate ConfigCommand to modular dependency injection (flutter/flutter#190743)
2026-08-28 [email protected] Roll Skia from 37459da0a755 to 11e3a7cb0fd0 (9 revisions) (flutter/flutter#191929)
2026-08-28 [email protected] Connect to moved-to-rect after the window is realized (flutter/flutter#191773)
2026-08-28 [email protected] macOS: Compare accessibility strings as NSStrings in tests (flutter/flutter#191853)
2026-08-28 [email protected] macOS: Record test accessibility notifications in a dictionary (flutter/flutter#191854)
2026-08-28 [email protected] Roll Fuchsia Test Scripts from 6SXRz6wsA2Zm_rAqP... to u_fSMsPU22VvUsvSo... (flutter/flutter#191927)
2026-08-28 [email protected] Roll Dart SDK from cb4c39d067f3 to e030e77d5413 (3 revisions) (flutter/flutter#191923)
2026-08-27 [email protected] Migrate ios driver tests batch 2 to simulators (flutter/flutter#190930)
2026-08-27 [email protected] [flutter_test] Ensure LiveTestWidgetsFlutterBinding executes frame and pointer callbacks in the test zone (flutter/flutter#191595)
2026-08-27 [email protected] Deprecate legacy gen_defaults tool (flutter/flutter#191911)
2026-08-27 [email protected] Fix black window in the subsurface view renderer (flutter/flutter#191850)
2026-08-27 [email protected] Roll Skia from 82e972ea84b1 to 37459da0a755 (10 revisions) (flutter/flutter#191906)
2026-08-27 [email protected] iOS: Key the platform view factory registries by NSString (flutter/flutter#191855)
2026-08-27 [email protected] Sync CHANGELOG.md from stable (flutter/flutter#191895)
2026-08-27 [email protected] [flutter_tools] Honor configured build-dir across flutter project and build targets (flutter/flutter#191592)
2026-08-27 [email protected] Revert: Handle linear and radial gradients in UberSDF (flutter/flutter#191913)
2026-08-27 [email protected] Explicitly disable HCPP in hybrid_android_views integration test (flutter/flutter#191894)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages
Please CC [email protected],[email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CICD Run CI/CD f: routes Navigator, Router, and related APIs. team-ios Owned by iOS platform team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants