swc/.github/workflows/bench.yml
강동윤 28bb61fb8d
fix(swc): Fix bugs (#1624)
spack:
 - Add ability to exclude module from the bundle. (#1385)

swc_ecma_ast:
 - Make `Param.decorators` optional. (#1603).

swc_ecma_transforms_compat:
 - Fix super calls in seq exprs in a class. (#1617)

swc_ecma_transforms_module:
- `common_js`: Fix dynamic imports. (#1614)

swc_ecma_transforms_typescript:
 - Fix common js imports. (#1593)
2021-04-30 06:25:24 +00:00

59 lines
1.5 KiB
YAML

name: Benchmark
on:
- push
- pull_request
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Cache
uses: actions/cache@v1
with:
path: |
./cache
~/.cargo/
target
Cargo.lock
key: ${{ runner.os }}-benchmark
- name: Run benchmark
run: cargo bench --all --no-run
benchmark:
name: Performance regression check
runs-on: ubuntu-latest
needs:
- build
steps:
- uses: actions/checkout@v2
- name: Cache
uses: actions/cache@v1
with:
path: |
./cache
~/.cargo/
target
Cargo.lock
key: ${{ runner.os }}-benchmark
- name: Run benchmark
run: cargo bench --all | tee output.txt
# Run `github-action-benchmark` action
- name: Store benchmark result
uses: rhysd/github-action-benchmark@v1
with:
# What benchmark tool the output.txt came from
tool: "cargo"
# Where the output from the benchmark tool is stored
output-file-path: output.txt
# Where the previous data file is stored
external-data-json-path: ./cache/benchmark-data.json
# Workflow will fail when an alert happens
fail-on-alert: true
# GitHub API token to make a commit comment
github-token: ${{ secrets.GITHUB_TOKEN }}
# Enable alert commit comment
comment-on-alert: true