Files
trezor-suite/.github/workflows/test-suite-desktop-e2e-release.yml

101 lines
3.0 KiB
YAML

name: "[Test] Release Suite Desktop e2e tests"
# Triggered by push to release branch
# Builds the desktop app
# Runs full e2e test suite for Suite Desktop
permissions:
id-token: write # for fetching the OIDC token
contents: read # for actions/checkout
on:
push:
branches:
- release/2*
workflow_dispatch:
inputs:
publish_results_to_github:
description: "Publish test report to GitHub Project"
required: false
default: false
type: boolean
workflow_call:
inputs:
publish_results_to_github:
description: "Publish test report to GitHub Project"
required: false
default: false
type: boolean
concurrency:
group: desktop-${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
build-app:
if: github.repository == 'trezor/trezor-suite'
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Build and Upload Suite Desktop
uses: ./.github/actions/build-desktop
run-e2e-suite-desktop-tests:
if: github.repository == 'trezor/trezor-suite'
runs-on: ubuntu-24.04
needs:
- build-app
strategy:
fail-fast: false
matrix:
TEST_GROUP: [1, 2, 3, 4, 5, 6, 7]
steps:
- name: Generate GitHub App token
id: trezor-bot-token
uses: actions/create-github-app-token@v1
with:
app-id: ${{ secrets.TREZOR_BOT_APP_ID }}
private-key: ${{ secrets.TREZOR_BOT_PRIVATE_KEY }}
- name: Checkout
uses: actions/checkout@v4
with:
submodules: true
ref: ${{ github.sha }}
- name: Setup node
uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: yarn
- name: Download build artifact
uses: actions/download-artifact@v4
with:
name: desktop-app-build-e2e
- name: Extract build artifact
run: tar -xzf app-build.tar.gz -C ${{ github.workspace }}/packages/suite-desktop
- name: Extract Release Build
id: extract_branch
shell: bash
run: |
echo "release_build=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}-${GITHUB_SHA:0:7}" >> $GITHUB_ENV
- name: Run Playwright E2E Tests
uses: ./.github/actions/run-e2e-tests
with:
project: "desktop"
containers: "trezor-user-env-unix bitcoin-regtest electrum-regtest"
workspace-dependencies: "@trezor/suite-desktop"
test-group: ${{ matrix.TEST_GROUP }}
additional-grep-invert: "@nightlyOnly"
fail-fast: false
currents-project-id: "4ytF0E"
currents-record-key: ${{ secrets.CURRENTS_RECORD_KEY }}
e2e-passphrase: ${{ secrets.E2E_TEST_PASSPHRASE }}
github-token: ${{ steps.trezor-bot-token.outputs.token }}
release-build: ${{ env.release_build }}
run-reporter: ${{ inputs.publish_results_to_github == true }}