Skip to content

Commit

Permalink
Merge pull request #256 from alcides/codspeed
Browse files Browse the repository at this point in the history
Added CodSpeed support
  • Loading branch information
alcides authored Nov 6, 2024
2 parents 8fcbe4d + d6c2814 commit 205b80c
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/codspeed.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: CodSpeed

on:
push:
branches:
- "main" # or "master"
pull_request:
# `workflow_dispatch` allows CodSpeed to trigger backtest
# performance analysis in order to generate initial data.
workflow_dispatch:

jobs:
codspeed:
name: Run benchmarks
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-python@v3
with:
python-version: "3.12"

- name: Install dev dependencies
run: pip install -r requirements-dev.txt
- name: Install dependencies
run: pip install -r requirements.txt
- name: Install geneticengine
run: pip install -e .

- name: Run benchmarks
uses: CodSpeedHQ/action@v3
with:
token: ${{ secrets.CODSPEED_TOKEN }}
run: pytest tests/ --codspeed
1 change: 1 addition & 0 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@ pre-commit
pycln
pytest
pytest-cov
pytest-codspeed
ruff

0 comments on commit 205b80c

Please sign in to comment.