Skip to content

cancel md5sum progress #130

cancel md5sum progress

cancel md5sum progress #130

Workflow file for this run

name: Benchmark server
on:
push:
branches:
- main
pull_request:
permissions:
contents: write
jobs:
benchmark:
name: Run pytest-benchmark
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: "3.10"
- name: Run benchmark
run: |
cd server
pip install -r requirements.txt -r test-requirements.txt
pytest buildoutls/bench/slapos.py --benchmark-json ../benchmark-data.json
- name: Download previous benchmark data
uses: actions/cache@v1
with:
path: ./cache
key: ${{ runner.os }}-benchmark
- name: Initialise base benchmark result (pull request)
run: |
if test -f ./cache/benchmark-data-main.json ; then cp ./cache/benchmark-data-main.json ./cache/benchmark-data-pull-request.json ; fi
if: ${{ github.event_name == 'pull_request' }}
- name: Store benchmark result (pull request)
uses: benchmark-action/[email protected]
with:
name: Python Benchmark with pytest-benchmark
tool: "pytest"
output-file-path: benchmark-data.json
external-data-json-path: ./cache/benchmark-data-pull-request.json
alert-threshold: "110%"
fail-threshold: "120%"
if: ${{ github.event_name == 'pull_request' }}
- name: Store benchmark result (main)
uses: benchmark-action/[email protected]
with:
name: Python Benchmark with pytest-benchmark
tool: "pytest"
output-file-path: benchmark-data.json
external-data-json-path: ./cache/benchmark-data-main.json
alert-threshold: "110%"
fail-threshold: "120%"
if: ${{ github.event_name == 'push' }}