Adds CI coverage for the existing Detox iOS E2E suites in RNApp, ExpoApp54, and ExpoApp55. #823
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
| name: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| workflow_dispatch: | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
| cancel-in-progress: true | |
| permissions: | |
| contents: read | |
| actions: write | |
| jobs: | |
| filter: | |
| name: Detect changed paths | |
| runs-on: ubuntu-latest | |
| outputs: | |
| packages: ${{ steps.filter.outputs.packages }} | |
| rnapp: ${{ steps.filter.outputs.rnapp }} | |
| expo54: ${{ steps.filter.outputs.expo54 }} | |
| expo55: ${{ steps.filter.outputs.expo55 }} | |
| androidapp: ${{ steps.filter.outputs.androidapp }} | |
| appleapp: ${{ steps.filter.outputs.appleapp }} | |
| ci: ${{ steps.filter.outputs.ci }} | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6 | |
| - name: Filter paths | |
| uses: dorny/paths-filter@v3 | |
| id: filter | |
| with: | |
| filters: | | |
| packages: | |
| - 'packages/**' | |
| rnapp: | |
| - 'apps/RNApp/**' | |
| - 'apps/brownfield-example-shared-tests/**' | |
| expo54: | |
| - 'apps/ExpoApp54/**' | |
| - 'apps/brownfield-example-shared-tests/**' | |
| expo55: | |
| - 'apps/ExpoApp55/**' | |
| - 'apps/brownfield-example-shared-tests/**' | |
| androidapp: | |
| - 'apps/AndroidApp/**' | |
| appleapp: | |
| - 'apps/AppleApp/**' | |
| ci: | |
| - '.github/**' | |
| check-changeset: | |
| name: Check changeset | |
| runs-on: ubuntu-latest | |
| needs: filter | |
| if: needs.filter.outputs.packages == 'true' | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6 | |
| with: | |
| fetch-depth: 0 | |
| - name: Setup | |
| uses: ./.github/actions/setup | |
| - name: Check changeset | |
| if: github.ref != 'refs/heads/main' | |
| run: yarn changeset status --since=origin/${{ github.base_ref }} | |
| build-lint: | |
| name: Build, lint, typecheck & Jest | |
| runs-on: ubuntu-latest | |
| needs: filter | |
| if: needs.filter.outputs.packages == 'true' || needs.filter.outputs.ci == 'true' | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6 | |
| - name: Setup | |
| uses: ./.github/actions/setup | |
| - name: Build packages | |
| run: yarn build | |
| - name: Lint files | |
| run: yarn lint | |
| - name: Typecheck files | |
| run: yarn typecheck | |
| - name: Run app tests (Jest) | |
| run: yarn test:apps | |
| - name: Test Brownfield CLI (version) | |
| run: | | |
| yarn workspace @callstack/react-native-brownfield brownfield --version | |
| ios-native-tests: | |
| name: iOS native tests | |
| runs-on: macos-26 | |
| needs: build-lint | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6 | |
| - name: Setup | |
| uses: ./.github/actions/setup | |
| - name: Run Swift bundle resolver tests | |
| run: | | |
| cd packages/react-native-brownfield/ios/swiftpm | |
| mkdir -p "$RUNNER_TEMP/swift-home" "$RUNNER_TEMP/swift-cache/clang" "$RUNNER_TEMP/swift-cache/swiftpm" | |
| HOME="$RUNNER_TEMP/swift-home" \ | |
| CLANG_MODULE_CACHE_PATH="$RUNNER_TEMP/swift-cache/clang" \ | |
| swift test --scratch-path "$RUNNER_TEMP/swift-cache/swiftpm" | |
| android-androidapp-expo: | |
| name: Android road test (AndroidApp - Expo ${{ matrix.version }}) | |
| runs-on: ubuntu-latest | |
| needs: [filter, build-lint] | |
| if: | | |
| always() && | |
| ( | |
| needs.filter.outputs.expo54 == 'true' || | |
| needs.filter.outputs.expo55 == 'true' || | |
| needs.filter.outputs.androidapp == 'true' || | |
| needs.filter.outputs.packages == 'true' || | |
| needs.filter.outputs.ci == 'true' | |
| ) && | |
| (needs.build-lint.result == 'success' || needs.build-lint.result == 'skipped') | |
| strategy: | |
| matrix: | |
| include: | |
| - version: '54' | |
| - version: '55' | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6 | |
| - name: Run RNApp -> AndroidApp road test (Expo ${{ matrix.version }}) | |
| uses: ./.github/actions/androidapp-road-test | |
| with: | |
| flavor: expo${{ matrix.version }} | |
| rn-project-path: apps/ExpoApp${{ matrix.version }} | |
| rn-project-maven-path: com/callstack/rnbrownfield/demo/expoapp${{ matrix.version }}/brownfieldlib | |
| android-androidapp-vanilla: | |
| name: Android road test (AndroidApp - Vanilla) | |
| runs-on: ubuntu-latest | |
| needs: [filter, build-lint] | |
| if: | | |
| always() && | |
| ( | |
| needs.filter.outputs.rnapp == 'true' || | |
| needs.filter.outputs.androidapp == 'true' || | |
| needs.filter.outputs.packages == 'true' || | |
| needs.filter.outputs.ci == 'true' | |
| ) && | |
| (needs.build-lint.result == 'success' || needs.build-lint.result == 'skipped') | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6 | |
| - name: Run RNApp -> AndroidApp road test (Vanilla) | |
| uses: ./.github/actions/androidapp-road-test | |
| with: | |
| flavor: vanilla | |
| rn-project-path: apps/RNApp | |
| rn-project-maven-path: com/rnapp/brownfieldlib | |
| ios-appleapp-vanilla: | |
| name: iOS road test (AppleApp - Vanilla) | |
| runs-on: macos-26 | |
| needs: [filter, build-lint] | |
| if: | | |
| always() && | |
| ( | |
| needs.filter.outputs.rnapp == 'true' || | |
| needs.filter.outputs.appleapp == 'true' || | |
| needs.filter.outputs.packages == 'true' || | |
| needs.filter.outputs.ci == 'true' | |
| ) && | |
| (needs.build-lint.result == 'success' || needs.build-lint.result == 'skipped') | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6 | |
| - name: Run RNApp -> AppleApp road test (Vanilla) | |
| uses: ./.github/actions/appleapp-road-test | |
| with: | |
| variant: vanilla | |
| rn-project-path: apps/RNApp | |
| ios-appleapp-expo: | |
| name: iOS road test (AppleApp - Expo ${{ matrix.version }}) | |
| runs-on: macos-26 | |
| needs: [filter, build-lint] | |
| if: | | |
| always() && | |
| ( | |
| needs.filter.outputs.expo54 == 'true' || | |
| needs.filter.outputs.expo55 == 'true' || | |
| needs.filter.outputs.appleapp == 'true' || | |
| needs.filter.outputs.packages == 'true' || | |
| needs.filter.outputs.ci == 'true' | |
| ) && | |
| (needs.build-lint.result == 'success' || needs.build-lint.result == 'skipped') | |
| strategy: | |
| matrix: | |
| include: | |
| - version: '54' | |
| - version: '55' | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6 | |
| - name: Run ExpoApp -> AppleApp road test (Expo ${{ matrix.version }}) | |
| uses: ./.github/actions/appleapp-road-test | |
| with: | |
| variant: expo${{ matrix.version }} | |
| rn-project-path: apps/ExpoApp${{ matrix.version }} | |
| e2e-ios-rnapp: | |
| name: E2E iOS (RNApp) | |
| runs-on: macos-26 | |
| timeout-minutes: 90 | |
| permissions: | |
| contents: read | |
| actions: write | |
| needs: [filter, build-lint] | |
| if: | | |
| always() && | |
| ( | |
| needs.filter.outputs.rnapp == 'true' || | |
| needs.filter.outputs.packages == 'true' || | |
| needs.filter.outputs.ci == 'true' | |
| ) && | |
| (needs.build-lint.result == 'success' || needs.build-lint.result == 'skipped') | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6 | |
| - name: Run Detox E2E (RNApp) | |
| uses: ./.github/actions/e2e-ios | |
| with: | |
| app-path: apps/RNApp | |
| artifact-name: detox-rnapp | |
| run-brownfield-codegen: 'true' | |
| e2e-ios-expo: | |
| name: E2E iOS (Expo ${{ matrix.version }}) | |
| runs-on: macos-26 | |
| timeout-minutes: 90 | |
| permissions: | |
| contents: read | |
| actions: write | |
| needs: [filter, build-lint] | |
| if: | | |
| always() && | |
| ( | |
| needs.filter.outputs.expo54 == 'true' || | |
| needs.filter.outputs.expo55 == 'true' || | |
| needs.filter.outputs.packages == 'true' || | |
| needs.filter.outputs.ci == 'true' | |
| ) && | |
| (needs.build-lint.result == 'success' || needs.build-lint.result == 'skipped') | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - version: '54' | |
| - version: '55' | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6 | |
| - name: Run Detox E2E (Expo ${{ matrix.version }}) | |
| uses: ./.github/actions/e2e-ios | |
| with: | |
| app-path: apps/ExpoApp${{ matrix.version }} | |
| artifact-name: detox-expo${{ matrix.version }} | |
| run-expo-prebuild: 'true' |