fix(e2e): stabilize flaky iOS AppleApp Detox tests#428
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR aims to stabilize flaky iOS Detox E2E tests for the AppleApp brownfield host by adjusting RN layout behavior on the Home screen, tuning Detox timing budgets, and taking more explicit control over Detox synchronization during embedded RN/Expo readiness checks.
Changes:
- Adjust RNApp Home screen layout styles to avoid flaky/unstable rendering of the message section/list.
- Add an option to keep Detox synchronization disabled after launch, and use manual sync handling during AppleApp readiness waits.
- Increase shared E2E timing budgets to better tolerate slow CI cold starts.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| apps/RNApp/src/HomeScreen.tsx | Tweaks flex layout for the message section/list to stabilize visibility/layout. |
| apps/brownfield-example-shared-tests/e2e/detoxUtils.cjs | Adds enableSync option to app launch helper and keeps sync enabling conditional. |
| apps/brownfield-example-shared-tests/e2e/detoxTiming.cjs | Raises shared timeouts used by Detox/Jest configuration. |
| apps/brownfield-example-shared-tests/e2e/appleAppExpoBrownfield.e2e.js | Launches AppleApp with sync initially disabled for embedded Expo readiness. |
| apps/brownfield-example-shared-tests/e2e/appleAppDetoxUtils.cjs | Disables sync during AppleApp readiness waits and adjusts readiness polling behavior. |
| apps/brownfield-example-shared-tests/e2e/appleAppBrownfield.e2e.js | Launches AppleApp with sync initially disabled for embedded RN (Vanilla) readiness. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
287
to
292
| messageSection: { | ||
| flex: 1, | ||
| minHeight: 0, | ||
| flexGrow: 1, | ||
| flexBasis: 'auto', | ||
| width: '100%', | ||
| marginTop: 12, | ||
| }, |
| * fails because Detox is not connected to the app yet. | ||
| */ | ||
| async function launchBrownfieldAppForDetox({ newInstance = true } = {}) { | ||
| async function launchBrownfieldAppForDetox({ |
Comment on lines
+231
to
+232
| 60_000 | ||
| ); |
|
|
||
| /** Timeout for the entire E2E test suite (detox + Jest + Maestro). */ | ||
| TEST_TIMEOUT_MS: 300_000, | ||
| TEST_TIMEOUT_MS: 720_000, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Test plan