Skip to content

Continuous benchmarking #6

Continuous benchmarking

Continuous benchmarking #6

Workflow file for this run

name: Continuous benchmarking
on:
pull_request:
branches:
- master
push:
branches:
- master
permissions:
contents: write
deployments: write
jobs:
benchmark:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup .NET SDK
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
- name: Run benchmarks
working-directory: src/Benchmarks
run: dotnet run -c Release --exporters json --filter '*'
- name: Combine benchmarks results
working-directory: src/Benchmarks
run: dotnet tool install -g dotnet-script && dotnet script combine-bechmarks.csx
- name: Store benchmarks results
uses: benchmark-action/github-action-benchmark@v1
with:
name: SteroidsDI Benchmarks
tool: 'benchmarkdotnet'
output-file-path: src/Benchmarks/BenchmarkDotNet.Artifacts/results/Combined.Benchmarks.json
github-token: ${{ secrets.GITHUB_TOKEN }}
alert-threshold: '101%'
comment-on-alert: true
fail-on-alert: true
- name: Push benchmarks results
if: github.event_name != 'pull_request'
run: git push 'https://sungam3r:${{ secrets.GITHUB_TOKEN }}@github.com/sungam3r/SteroidsDI.git' gh-pages:gh-pages