⬆️ Upgrade dependency rollup to v4 #2118
This file contains 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: E2E Tests | |
on: | |
pull_request: | |
branches: | |
- '**' | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | |
jobs: | |
setup: | |
if: 'false' | |
runs-on: ubuntu-latest | |
timeout-minutes: 30 | |
outputs: | |
plugins: ${{ steps.e2e-packages.outputs.e2e-paths }} | |
steps: | |
- uses: dtinth/setup-github-actions-caching-for-turbo@cc723b4600e40a6b8815b65701d8614b91e2669e # v1 | |
- uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4 | |
with: | |
node-version-file: .tool-versions | |
cache: yarn | |
- run: yarn install | |
- id: files | |
uses: imhoffd/get-changed-files@4064453b1b00f8f8d17f1493c90fbe1f9c40daff # v2 | |
with: | |
format: json | |
- id: packages | |
uses: ./.github/actions/changed-packages | |
with: | |
files: ${{ steps.files.outputs.all }} | |
- id: e2e-packages | |
uses: ./.github/actions/filter-out-non-e2e-enabled | |
with: | |
paths: ${{ steps.packages.outputs.paths }} | |
e2e-ios: | |
runs-on: macos-14 | |
timeout-minutes: 35 | |
if: needs.setup.outputs.plugins != '[]' | |
needs: | |
- setup | |
strategy: | |
matrix: | |
plugin: ${{ fromJson(needs.setup.outputs.plugins) }} | |
defaults: | |
run: | |
working-directory: ${{ matrix.plugin }}/e2e-tests | |
steps: | |
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 | |
- uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4 | |
with: | |
node-version-file: .tool-versions | |
cache: yarn | |
- name: Prepare Local Package | |
run: yarn install && yarn run build && npm run pack-local | |
working-directory: ${{ matrix.plugin }} | |
env: | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
- name: Setup NPMRC | |
run: echo "//registry.npmjs.org/:_authToken=${{secrets.E2E_NPM_TOKEN}}" > .npmrc | |
- name: Prepare Local Package | |
run: npm run e2e:prepare | |
env: | |
NPM_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }} | |
- name: Install Packages | |
run: yarn install | |
env: | |
NPM_TOKEN: ${{ secrets.E2E_NPM_TOKEN }} | |
- name: Run E2E Test on iOS | |
run: npm run e2e:ios | |
env: | |
REACT_APP_GOOGLE_MAPS_API_KEY: ${{ secrets.REACT_APP_GOOGLE_MAPS_API_KEY }} | |
e2e-android: | |
runs-on: macos-10.15 | |
timeout-minutes: 35 | |
if: needs.setup.outputs.plugins != '[]' | |
needs: | |
- setup | |
strategy: | |
matrix: | |
plugin: ${{ fromJson(needs.setup.outputs.plugins) }} | |
defaults: | |
run: | |
working-directory: ${{ matrix.plugin }}/e2e-tests | |
steps: | |
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 | |
- uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4 | |
with: | |
node-version-file: .tool-versions | |
cache: yarn | |
- name: Prepare Local Package | |
run: npm run e2e:prepare | |
env: | |
NPM_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }} | |
- name: Prepare Local Package | |
run: yarn install && npm run build && npm run pack-local | |
working-directory: ${{ matrix.plugin }} | |
env: | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
- name: Setup NPMRC | |
run: echo "//registry.npmjs.org/:_authToken=${{secrets.E2E_NPM_TOKEN}}" > .npmrc | |
- name: Setup local.properties | |
run: echo "REACT_APP_GOOGLE_MAPS_API_KEY=${{secrets.REACT_APP_GOOGLE_MAPS_API_KEY}}" > android/local.properties | |
- name: Install Packages | |
run: yarn install | |
env: | |
NPM_TOKEN: ${{ secrets.E2E_NPM_TOKEN }} | |
- name: AVD cache | |
uses: actions/cache@6849a6489940f00c2f30c0fb92c6274307ccb58a # v4 | |
id: avd-cache | |
with: | |
path: | | |
~/.android/avd/* | |
~/.android/adb* | |
key: avd-adb-p3a-30-cache-2 | |
- name: Create AVD and generate snapshot for caching | |
if: steps.avd-cache.outputs.cache-hit != 'true' | |
uses: reactivecircus/android-emulator-runner@62dbb605bba737720e10b196cb4220d374026a6d # v2 | |
with: | |
avd-name: e2eDevice | |
api-level: 30 | |
target: google_apis | |
arch: x86 | |
profile: pixel_3a | |
emulator-build: 7759208 | |
force-avd-creation: true | |
emulator-options: -no-window -no-audio -no-boot-anim -accel on | |
script: echo "Generated AVD snapshot for caching." | |
- name: Run E2E Test on Android | |
uses: reactivecircus/android-emulator-runner@62dbb605bba737720e10b196cb4220d374026a6d # v2 | |
with: | |
avd-name: e2eDevice | |
api-level: 30 | |
target: google_apis | |
arch: x86 | |
profile: pixel_3a | |
working-directory: ${{ matrix.plugin }}/e2e-tests | |
emulator-build: 7759208 | |
emulator-options: -no-window -no-audio -no-boot-anim -accel on -no-snapshot-save | |
disable-animations: false | |
script: npm run e2e:android | |
env: | |
REACT_APP_GOOGLE_MAPS_API_KEY: ${{ secrets.REACT_APP_GOOGLE_MAPS_API_KEY }} |