Skip to content

Run E2E tests on each PR #52197

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 1 addition & 8 deletions .github/actions/build-android/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@ inputs:
release-type:
required: true
description: The type of release we are building. It could be nightly, release or dry-run
run-e2e-tests:
default: 'false'
description: If we need to build to run E2E tests. If yes, we need to build also x86.
gradle-cache-encryption-key:
description: "The encryption key needed to store the Gradle Configuration cache"
runs:
Expand Down Expand Up @@ -43,11 +40,7 @@ runs:
run: |
if [[ "${{ inputs.release-type }}" == "dry-run" ]]; then
# dry-run: we only build ARM64 to save time/resources. For release/nightlies the default is to build all archs.
if [[ "${{ inputs.run-e2e-tests }}" == 'true' ]]; then
export ORG_GRADLE_PROJECT_reactNativeArchitectures="arm64-v8a,x86" # x86 is required for E2E testing
else
export ORG_GRADLE_PROJECT_reactNativeArchitectures="arm64-v8a"
fi
export ORG_GRADLE_PROJECT_reactNativeArchitectures="arm64-v8a,x86" # x86 is required for E2E testing
TASKS="publishAllToMavenTempLocal build"
elif [[ "${{ inputs.release-type }}" == "nightly" ]]; then
# nightly: we set isSnapshot to true so artifacts are sent to the right repository on Maven Central.
Expand Down
12 changes: 1 addition & 11 deletions .github/workflows/test-all.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@ name: Test All

on:
workflow_dispatch:
inputs:
run-e2e-tests:
description: Whether to run E2E tests or not
type: boolean
default: false
pull_request:
push:
branches:
Expand Down Expand Up @@ -187,7 +182,6 @@ jobs:
flavor: ${{ matrix.flavor }}

test_e2e_ios_rntester:
if: ${{ github.ref == 'refs/heads/main' || contains(github.ref, 'stable') || inputs.run-e2e-tests }}
runs-on: macos-14-large
needs:
[test_ios_rntester]
Expand Down Expand Up @@ -221,7 +215,6 @@ jobs:
flavor: ${{ matrix.flavor }}

test_e2e_ios_templateapp:
if: ${{ github.ref == 'refs/heads/main' || contains(github.ref, 'stable') || inputs.run-e2e-tests }}
runs-on: macos-14-large
needs: [build_npm_package, prebuild_apple_dependencies]
env:
Expand Down Expand Up @@ -305,7 +298,6 @@ jobs:
working-directory: /tmp/RNTestProject

test_e2e_android_templateapp:
if: ${{ github.ref == 'refs/heads/main' || contains(github.ref, 'stable') || inputs.run-e2e-tests }}
runs-on: 4-core-ubuntu
needs: build_npm_package
strategy:
Expand Down Expand Up @@ -424,11 +416,9 @@ jobs:
uses: ./.github/actions/build-android
with:
release-type: ${{ needs.set_release_type.outputs.RELEASE_TYPE }}
run-e2e-tests: ${{ github.ref == 'refs/heads/main' || contains(github.ref, 'stable') || inputs.run-e2e-tests }}
gradle-cache-encryption-key: ${{ secrets.GRADLE_CACHE_ENCRYPTION_KEY }}

test_e2e_android_rntester:
if: ${{ github.ref == 'refs/heads/main' || contains(github.ref, 'stable') || inputs.run-e2e-tests }}
runs-on: 4-core-ubuntu
needs: [build_android]
strategy:
Expand Down Expand Up @@ -626,7 +616,7 @@ jobs:
rerun-failed-jobs:
runs-on: ubuntu-latest
needs: [test_e2e_ios_rntester, test_e2e_android_rntester, test_e2e_ios_templateapp, test_e2e_android_templateapp]
if: always()
if: ${{ github.ref == 'refs/heads/main' && always() }}
steps:
- name: Checkout
uses: actions/checkout@v4
Expand Down
Loading