also looking at this
fix(mobile): preserve native editing, navigation, and durable media requests
#369
36 files
+864
-185
Review threads live on the whole diff, not on one commit, so none are shown here - a thread's line means something in the branch's final form, and painting it into an intermediate step would put it on code it is not about.
| @@ -137,11 +137,11 @@ jobs: | ||
| 137 | 137 | strategy: |
| 138 | 138 | fail-fast: false |
| 139 | 139 | matrix: |
| 140 | suite: ${{ fromJSON(inputs.scope == 'ios-render' && '["uikit"]' || inputs.scope == 'ios-navigation' && inputs.selectors != '' && '["navigation"]' || inputs.scope == 'ios-navigation' && '["navigation-unit","navigation-ui"]' || '["uikit","navigation-unit","navigation-ui"]') }} | |
| 140 | suite: ${{ fromJSON(inputs.scope == 'ios-render' && '["uikit"]' || inputs.scope == 'ios-navigation' && inputs.selectors != '' && '["navigation"]' || inputs.scope == 'ios-navigation' && '["navigation-unit","navigation-ui-core","navigation-ui-controls"]' || '["uikit","navigation-unit","navigation-ui-core","navigation-ui-controls"]') }} | |
| 141 | 141 | runs-on: macos-15 |
| 142 | # UIKit reconciliation and both navigation XCTest targets each get a fresh | |
| 143 | # runner and result bundle. Combining unit and UI navigation exceeded the | |
| 144 | # existing job budget; all targets remain required with the same backstop. | |
| 142 | # Every navigation UI case belongs to exactly one required group. The large | |
| 143 | # controls journey gets its own runner; core navigation, unit reconciliation | |
| 144 | # and UIKit retain separate results and the same bounded backstop. | |
| 145 | 145 | timeout-minutes: 45 |
| 146 | 146 | env: |
| 147 | 147 | CRAFT_EVIDENCE_LABEL: ios-native |
| @@ -196,7 +196,8 @@ jobs: | ||
| 196 | 196 | if: ${{ !cancelled() && startsWith(matrix.suite, 'navigation') }} |
| 197 | 197 | env: |
| 198 | 198 | STX_CLI: ${{ github.workspace }}/.stx-compiler/packages/stx/bin/cli.ts |
| 199 | CRAFT_ONLY_TESTING: ${{ matrix.suite == 'navigation-unit' && 'NativeNavigationUnitTests' || matrix.suite == 'navigation-ui' && 'NativeNavigationUITests' || inputs.selectors }} | |
| 199 | CRAFT_ONLY_TESTING: ${{ matrix.suite == 'navigation-unit' && 'NativeNavigationUnitTests' || inputs.selectors }} | |
| 200 | CRAFT_NATIVE_NAVIGATION_GROUP: ${{ matrix.suite == 'navigation-ui-core' && 'core' || matrix.suite == 'navigation-ui-controls' && 'controls' || '' }} | |
| 200 | 201 | CRAFT_NATIVE_NAVIGATION_RESULT: ${{ github.workspace }}/artifacts/mobile-e2e/ios-native/navigation.xcresult |
| 201 | 202 | run: | |
| 202 | 203 | mkdir -p artifacts/mobile-e2e/ios-native |
| @@ -129,15 +129,19 @@ test('navigation shards retain both complete XCTest targets and focused selectio | ||
| 129 | 129 | startsWith: (text: string, prefix: string) => text.startsWith(prefix), cancelled: () => false, |
| 130 | 130 | }, { timeout: 100 }) |
| 131 | 131 | for (const scope of ['', 'all']) |
| 132 | expect(evaluate(expression, scope)).toEqual(['uikit', 'navigation-unit', 'navigation-ui']) | |
| 133 | expect(evaluate(expression, 'ios-navigation')).toEqual(['navigation-unit', 'navigation-ui']) | |
| 132 | expect(evaluate(expression, scope)).toEqual(['uikit', 'navigation-unit', 'navigation-ui-core', 'navigation-ui-controls']) | |
| 133 | expect(evaluate(expression, 'ios-navigation')).toEqual(['navigation-unit', 'navigation-ui-core', 'navigation-ui-controls']) | |
| 134 | 134 | expect(evaluate(expression, 'ios-render')).toEqual(['uikit']) |
| 135 | 135 | const focused = 'NativeNavigationUITests/NativeNavigationUITests/testMultilineInputKeepsKeyboardFocusWhenTapped' |
| 136 | 136 | expect(evaluate(expression, 'ios-navigation', focused)).toEqual(['navigation']) |
| 137 | 137 | expect(evaluate(navigation!.env!.CRAFT_ONLY_TESTING, 'all', '', 'navigation-unit')).toBe('NativeNavigationUnitTests') |
| 138 | expect(evaluate(navigation!.env!.CRAFT_ONLY_TESTING, 'all', '', 'navigation-ui')).toBe('NativeNavigationUITests') | |
| 138 | for (const [suite, group] of [['navigation-ui-core', 'core'], ['navigation-ui-controls', 'controls']]) { | |
| 139 | expect(evaluate(navigation!.env!.CRAFT_ONLY_TESTING, 'all', '', suite)).toBe('') | |
| 140 | expect(evaluate(navigation!.env!.CRAFT_NATIVE_NAVIGATION_GROUP, 'all', '', suite)).toBe(group) | |
| 141 | } | |
| 139 | 142 | expect(evaluate(navigation!.env!.CRAFT_ONLY_TESTING, 'ios-navigation', focused, 'navigation')).toBe(focused) |
| 140 | for (const suite of ['navigation-unit', 'navigation-ui', 'navigation']) | |
| 143 | expect(evaluate(navigation!.env!.CRAFT_NATIVE_NAVIGATION_GROUP, 'ios-navigation', focused, 'navigation')).toBe('') | |
| 144 | for (const suite of ['navigation-unit', 'navigation-ui-core', 'navigation-ui-controls', 'navigation']) | |
| 141 | 145 | expect(evaluate(navigation!.if!, 'all', '', suite)).toBe(true) |
| 142 | 146 | expect(evaluate(navigation!.if!, 'all', '', 'uikit')).toBe(false) |
| 143 | 147 | expect(native.strategy?.['fail-fast']).toBe(false) |