Skip to content

Commit 7206dcc

Browse files
robhoganmeta-codesync[bot]
authored andcommitted
Assert switch state before the toggled visual screenshot (#59413)
Summary: The custom-colors switch flow takes its `toggled` screenshot without checking the taps landed, so a dropped tap captures the wrong state. That spoiled a baseline on `main` and failed #59390. This asserts each switch's `checked` state before the screenshot, so a dropped tap fails the flow and it's retried instead. Changelog: [Internal] Pull Request resolved: #59413 Test Plan: Ran the section on the iOS 26 visual simulator: passes as written, and fails when asserting the wrong state. Android runs in this PR's CI. Reviewed By: cipolleschi Differential Revision: D127577122 Pulled By: cortinico fbshipit-source-id: 59bed882d9f1f7cdb553c170e2d897fc39f22e41
1 parent f76f251 commit 7206dcc

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

‎packages/rn-tester/visual-tests/flows/switch.yml‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,12 @@ appId: ${APP_ID}
8080
id: 'initial-false-switch'
8181
- tapOn:
8282
id: 'initial-true-switch'
83+
- assertVisible:
84+
id: 'initial-false-switch'
85+
checked: true
86+
- assertVisible:
87+
id: 'initial-true-switch'
88+
checked: false
8389
- waitForAnimationToEnd:
8490
timeout: 5000
8591
- takeScreenshot:

0 commit comments

Comments
 (0)