Commit | Line | Data |
---|---|---|
93874800 JB |
1 | name: Benchmark |
2 | ||
3 | on: | |
f1c674cd JB |
4 | push: |
5 | branches: | |
6 | - master | |
7 | ||
8 | permissions: | |
9 | contents: write | |
10 | deployments: write | |
93874800 JB |
11 | |
12 | jobs: | |
13 | internal-benchmark: | |
f1c674cd JB |
14 | name: Internal benchmark |
15 | runs-on: ubuntu-latest | |
93874800 JB |
16 | steps: |
17 | - name: Checkout | |
18 | uses: actions/checkout@v4 | |
93874800 JB |
19 | - name: Setup pnpm |
20 | uses: pnpm/action-setup@v2 | |
21 | with: | |
22 | version: 8 | |
f1c674cd | 23 | - name: Setup Node.js |
93874800 JB |
24 | uses: actions/setup-node@v3 |
25 | with: | |
f1c674cd | 26 | node-version: '18.x' |
93874800 | 27 | cache: 'pnpm' |
f1c674cd | 28 | - name: Install dependencies |
93874800 | 29 | run: pnpm install --ignore-scripts |
f1c674cd JB |
30 | - name: Run production benchmark |
31 | run: pnpm benchmark:prod | tee ./benchmarks/internal/output.txt | |
32 | - name: Store production benchmark result | |
33 | uses: benchmark-action/github-action-benchmark@v1 | |
34 | with: | |
35 | name: Internal benchmark | |
36 | tool: 'benchmarkjs' | |
37 | output-file-path: ./benchmarks/internal/output.txt | |
38 | github-token: ${{ secrets.GITHUB_TOKEN }} | |
39 | auto-push: true | |
40 | alert-threshold: '200%' | |
41 | comment-on-alert: true | |
42 | fail-on-alert: true | |
43 | gh-repository: 'github.com/poolifier/benchmark-results' |