Support/no more setup toolchain #11103
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: "[Test] Bridge" | |
on: pull_request | |
concurrency: | |
group: ci-bridge-${{ github.ref }} | |
permissions: | |
id-token: write | |
contents: read | |
jobs: | |
is-affected: | |
outputs: | |
is-affected: ${{ steps.affected.outputs.is-affected }} | |
paths: ${{ steps.affected.outputs.paths }} | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: develop | |
fetch-depth: 0 | |
- name: checkout branch (PR) | |
if: ${{ github.event_name == 'pull_request' }} | |
env: | |
GH_TOKEN: ${{ github.token }} | |
run: | | |
gh pr checkout ${{ github.event.pull_request.number }} | |
- name: checkout branch (not PR) | |
if: ${{ github.event_name != 'pull_request' }} | |
run: | | |
git checkout $GITHUB_SHA | |
- uses: LedgerHQ/ledger-live/tools/actions/live-common-affected@develop | |
id: affected | |
with: | |
ref: ${{ github.event_name == 'pull_request' && format('origin/{0}', github.event.pull_request.base.ref) || 'HEAD^' }} | |
bridge-tests: | |
name: "Bridge Tests" | |
needs: is-affected | |
if: ${{ needs.is-affected.outputs.is-affected == 'true' }} | |
env: | |
NODE_OPTIONS: "--max-old-space-size=7168" | |
FORCE_COLOR: 3 | |
CI_OS: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: | |
- [ledger-live-4xlarge] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup the caches | |
uses: LedgerHQ/ledger-live/tools/actions/composites/setup-caches@develop | |
id: setup-caches | |
with: | |
skip-turbo-cache: "false" | |
accountId: ${{ secrets.AWS_ACCOUNT_ID_PROD }} | |
roleName: ${{ secrets.AWS_CACHE_ROLE_NAME }} | |
region: ${{ secrets.AWS_CACHE_REGION }} | |
turbo-server-token: ${{ secrets.TURBOREPO_SERVER_TOKEN }} | |
- name: Install node-gyp globally | |
if: runner.os == 'Windows' | |
run: | | |
pnpm add -g [email protected] | |
- name: Install dependencies | |
run: pnpm i --filter="live-common..." --filter="ledger-live" | |
- name: Build | |
run: pnpm build:llc --api="http://127.0.0.1:${{ steps.setup-caches.outputs.port }}" --token="${{ secrets.TURBOREPO_SERVER_TOKEN }}" --team="foo" | |
- name: Test | |
shell: bash | |
env: | |
VERBOSE_FILE: logs.txt | |
run: | | |
pnpm common test-bridge | |
git diff --exit-code libs/ledger-live-common/src | |
- name: (On Failure) Upload live-common snapshots and source | |
uses: actions/upload-artifact@v4 | |
if: failure() | |
with: | |
name: ${{ format('live-common-src-{0}', matrix.os) }} | |
path: | | |
libs/ledger-live-common/src | |
- name: (On Failure) Upload logs | |
uses: actions/upload-artifact@v4 | |
if: failure() | |
with: | |
name: logs.txt | |
path: logs.txt |