Skip to content

feat: add CodSpeed to the project #408

feat: add CodSpeed to the project

feat: add CodSpeed to the project #408

Workflow file for this run

name: Benchmark
on:
push:
branches:
- main
pull_request:
paths:
- '.github/workflows/benchmark.yml'
- 'src/**'
- 'tests/**'
workflow_dispatch:
permissions:
contents: read
env:
CARGO_REGISTRIES_CRATES_IO_PROTOCOL: sparse
jobs:
benchmark:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
timeout-minutes: 3
- name: Clone test vectors
timeout-minutes: 2
uses: ./.github/actions/fetch-vectors
- name: Setup python
id: setup-python
uses: actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 # v5.2.0
with:
python-version: "3.12"
- name: Create virtualenv
run: |
python -m venv .venv
.venv/bin/pip install -v -c ./ci-constraints-requirements.txt "./[test]" ./vectors/
- name: Run benchmarks
uses: CodSpeedHQ/action@v2
with:
token: ${{ secrets.CODSPEED_TOKEN }}
run: .venv/bin/pytest --codspeed --benchmark-enable --benchmark-only ./tests/bench/ --benchmark-json=bench-pr.json --x509-limbo-root=x509-limbo/