Skip to content

[MA 3325] Config to opt for including element behind a modal on iOS #2515

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 7 commits into from

Conversation

amanjeetsingh150
Copy link
Collaborator

@amanjeetsingh150 amanjeetsingh150 commented Jun 3, 2025

Proposed changes

By default, iOS snapshots hide elements behind modals due to the snapshotKeyHonorModalViews flag being enabled. However, we've seen cases where elements visibly present on sheets are not captured properly — they're treated as if they're part of a container attached to the main window and not the sheet, and thus excluded.

This results in missing elements in the hierarchy even though they're visibly rendered on screen.

This PR introduces platform config to make a way to safely roll these features out.

  • This would be switched to default false in future
  • Users would have a way to opt out in cases test break.
executionOrder:
  flowsOrder:
    - flowB
    - flowC
    - flowD

platform: 
    ios: 
      snapshotKeyHonorModalViews: false

Impact

This improves visibility of UI elements rendered behind modals (e.g., sheets, alerts) during flow execution. Since this behavior changes how the hierarchy is built, it is opt-in to avoid breaking existing flows.

Testing

  • Customer flow locally
  • Sharding case

Copy link

linear bot commented Jun 3, 2025

Copy link

github-actions bot commented Jun 3, 2025

Make sure to run ./maestro-ios-xctest-runner/build-maestro-ios-runner.sh with every swift change

@amanjeetsingh150 amanjeetsingh150 force-pushed the MA-3325-include-non-modal branch from 4a19322 to 546c283 Compare June 9, 2025 09:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant