Skip to content

Commit

Permalink
feat: add CodSpeed to the project
Browse files Browse the repository at this point in the history
  • Loading branch information
adriencaccia authored and CodSpeed Install Bot committed Apr 17, 2024
1 parent 3169286 commit 36360fd
Show file tree
Hide file tree
Showing 9 changed files with 25 additions and 429 deletions.
28 changes: 7 additions & 21 deletions .github/workflows/benchmark.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ on:
push:
branches:
- main
pull_request:

permissions:
contents: write
Expand All @@ -12,9 +13,6 @@ jobs:
benchmark:
name: Run pytest-benchmark
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10"]
steps:
- name: Checkout Code
uses: actions/checkout@v4
Expand All @@ -23,27 +21,15 @@ jobs:
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
python-version: 3.12
- name: Install requirements (Python 3)
run: |
pip install -r requirements/ci.txt
pip install -r requirements/ci-3.11.txt
- name: Install pypdf
run: |
pip install .
- name: Run benchmark
run: |
pytest tests/bench.py --benchmark-json output.json
- name: Store benchmark result
uses: benchmark-action/github-action-benchmark@v1
- name: Run benchmarks
uses: CodSpeedHQ/action@v2
with:
name: Python Benchmark with pytest-benchmark
tool: 'pytest'
output-file-path: output.json
# Use personal access token instead of GITHUB_TOKEN due to https://github.community/t/github-action-not-triggering-gh-pages-upon-push/16096
github-token: ${{ secrets.GITHUB_TOKEN }}
auto-push: true
# Show alert with commit comment on detecting possible performance regression
alert-threshold: '200%'
comment-on-alert: true
fail-on-alert: true
alert-comment-cc-users: '@MartinThoma'
token: ${{ secrets.CODSPEED_TOKEN }}
run: pytest tests/bench.py --codspeed
41 changes: 0 additions & 41 deletions .github/workflows/create-github-release.yaml

This file was deleted.

233 changes: 0 additions & 233 deletions .github/workflows/github-ci.yaml

This file was deleted.

36 changes: 0 additions & 36 deletions .github/workflows/publish-to-pypi.yaml

This file was deleted.

Loading

0 comments on commit 36360fd

Please sign in to comment.