Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Benchmark tests workflow #4144

Merged
merged 9 commits into from
Sep 29, 2023
Merged
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 62 additions & 0 deletions .github/workflows/benchmark.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: Benchmark Tests

on:
release:
types: [published]

jobs:
node-tests:
strategy:
fail-fast: false
matrix:
node_version:
- "18"
runs-on: self-hosted
env:
NPM_CONFIG_UNSAFE_PERM: true
steps:
- name: Checkout
uses: actions/checkout@v3

- uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node_version }}

- run: npm install -g npm@latest

- name: restore lerna
id: cache
uses: actions/cache@v3
with:
path: |
node_modules
package-lock.json
packages/*/node_modules
packages/*/package-lock.json
experimental/packages/*/node_modules
experimental/packages/*/package-lock.json
key: node-tests-${{ runner.os }}-${{ matrix.node_version }}-${{ hashFiles('package.json', 'packages/*/package.json', 'experimental/packages/*/package.json') }}-04292022

- name: Bootstrap
run: |
npm install --ignore-scripts
npx lerna bootstrap --no-ci --hoist --nohoist='zone.js' --ignore @opentelemetry/selenium-tests

- name: Build 🔧
run: |
npm run compile

- name: Benchmark tests
run: |
npm run test:bench
find . -name benchmarks.txt -exec cat {} + > combined_benchmarks.txt

- name: Store benchmark results
uses: benchmark-action/github-action-benchmark@v1
with:
tool: 'benchmarkjs'
output-file-path: combined_benchmarks.txt
gh-pages-branch: benchmarks
github-token: ${{ secrets.GITHUB_TOKEN }}
benchmark-data-dir-path: "docs/benchmarks/loadtests"
auto-push: true
Loading