Skip to content

Commit

Permalink
Fix test_android_template (#44871)
Browse files Browse the repository at this point in the history
Summary:
Pull Request resolved: #44871

This re-enables and fix `test_android_template`.
The problem was that we were invoking `yarn install` inside the template after we already installed with `npm install --registry`.
So this was invalidating the Verdaccio setup and effectively fetching packages from NPM

Changelog:
[Internal] [Changed] - Fix test_android_template

Reviewed By: cipolleschi

Differential Revision: D58407941

fbshipit-source-id: 9b7b877cfc994eb8db1b5bf71dd35289c3937f5c
  • Loading branch information
cortinico authored and facebook-github-bot committed Jun 11, 2024
1 parent 54bbb2b commit 2867d66
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions .github/workflows/test-all.yml
Original file line number Diff line number Diff line change
Expand Up @@ -838,8 +838,6 @@ jobs:
-H "Authorization: Bearer $REACT_NATIVE_BOT_GITHUB_TOKEN" \
-d "{\"event_type\": \"publish\", \"client_payload\": { \"version\": \"${{ github.ref_name }}\" }}"
test_android_template:
# TODO: Re-enable once passing
if: ${{ github.event_name != 'pull_request' }}
runs-on: ubuntu-latest
needs: [prepare_hermes_workspace, build_npm_package]
container:
Expand Down Expand Up @@ -887,13 +885,7 @@ jobs:
node ./scripts/releases/update-template-package.js "{\"react-native\":\"file:$GITHUB_WORKSPACE/build/$(cat build/react-native-package-version)\"}"
node ./scripts/e2e/init-template-e2e.js --projectName $PROJECT_NAME --templatePath "$GITHUB_WORKSPACE/packages/react-native" --directory "/tmp/$PROJECT_NAME" --verbose
- name: Setup gradle
uses: gradle/actions/setup-gradle@v3
with:
gradle-version: 8.6
- name: Yarn install in template project
run: |
cd /tmp/$PROJECT_NAME
yarn install --non-interactive
uses: ./.github/actions/setup-gradle
- name: Build the template application for ${{ matrix.flavor }} with Architecture set to ${{ matrix.architecture }}, and using the ${{ matrix.jsengine }} JS engine.
shell: bash
run: |
Expand All @@ -915,6 +907,7 @@ jobs:
with:
name: template-apk-${{ matrix.flavor }}-${{ matrix.architecture }}-${{ matrix.jsengine }}
path: /tmp/AndroidTemplateProject/android/app/build/outputs/apk/
compression-level: 0
test_ios_template_with_ruby_3_2_0:
runs-on: macos-13
needs: [prepare_hermes_workspace, build_npm_package]
Expand Down

0 comments on commit 2867d66

Please sign in to comment.