Skip to content

B2CA-1584: Port Nano on NBGL #58

B2CA-1584: Port Nano on NBGL

B2CA-1584: Port Nano on NBGL #58

name: Build and run functional tests using ragger through reusable workflow
# This workflow will build the app and then run functional tests using the Ragger framework upon Speculos emulation.
# It calls a reusable workflow developed by Ledger's internal developer team to build the application and upload the
# resulting binaries.
# It then calls another reusable workflow to run the Ragger tests on the compiled application binary.
#
# While this workflow is optional, having functional testing on your application is mandatory and this workflow and
# tooling environment is meant to be easy to use and adapt after forking your application
on:
workflow_dispatch:
inputs:
golden_run:
type: choice
required: true
default: 'Raise an error (default)'
description: CI behavior if the test snapshots are different than expected.
options:
- 'Raise an error (default)'
- 'Open a PR'
push:
branches:
- master
- main
- develop
pull_request:
repository_dispatch:
types: [trigger-workflow]
jobs:
build_application_nbgl_test:
name: Build nbgl_test application using the reusable workflow
uses: LedgerHQ/ledger-app-workflows/.github/workflows/reusable_build.yml@v1
with:
upload_app_binaries_artifact: "compiled_app_binaries"
flags: "COIN=nbgl_test"
# TODO: to be removed once Nano is supported by the SDK
run_for_devices: '["stax", "flex"]'
build_application_demo:
name: Build demo application using the reusable workflow
uses: LedgerHQ/ledger-app-workflows/.github/workflows/reusable_build.yml@v1
with:
upload_app_binaries_artifact: "compiled_app_binaries_demo"
flags: "COIN=demo"
# TODO: to be removed once Nano is supported by the SDK
run_for_devices: '["stax", "flex"]'
ragger_tests:
name: Run ragger tests on nbgl_test using the reusable workflow
needs: build_application_nbgl_test
uses: LedgerHQ/ledger-app-workflows/.github/workflows/reusable_ragger_tests.yml@v1
with:
download_app_binaries_artifact: "compiled_app_binaries"
regenerate_snapshots: ${{ inputs.golden_run == 'Open a PR' }}
# TODO: to be removed once Nano is supported by the SDK
run_for_devices: '["stax", "flex"]'