Skip to content

perf regression guard detox #36951

perf regression guard detox

perf regression guard detox #36951

Workflow file for this run

name: 02-unittest
on:
workflow_dispatch:
pull_request:
branches:
- onekey
- x
push:
branches:
- onekey
- x
# Cancel a currently running workflow from the same PR/branch/tag
# when a new workflow is triggered
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
YARN_ENABLE_GLOBAL_CACHE: true
jobs:
unittest:
runs-on: ubuntu-24.04
strategy:
matrix:
node-version: [24.x]
steps:
- uses: actions/checkout@v4
with:
lfs: true
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v6
with:
node-version: ${{ matrix.node-version }}
cache: 'yarn'
registry-url: 'https://npm.pkg.github.com'
check-latest: true
scope: '@onekeyhq'
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "dir=${{ github.workspace }}/.yarn" >> "$GITHUB_OUTPUT"
- name: Install Dependency
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_OPTIONS: '--max_old_space_size=4096'
run: |
yarn install --immutable
- name: Run Tests
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_OPTIONS: '--max_old_space_size=8192'
run: |
yarn test
- name: Upload Test Report
uses: actions/upload-artifact@v4
if: always()
with:
name: test-report-${{ env.BUILD_NUMBER }}-${{ github.sha }}
path: test-report.html