Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run tests with uv #256

Open
wants to merge 9 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
151 changes: 0 additions & 151 deletions .github/workflows/cibuildwheel.yml

This file was deleted.

39 changes: 39 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Test

on:
push:
branches:
- main
pull_request:
paths-ignore:
- 'docs/**'
- 'examples/**'
workflow_call:

jobs:
style:
name: Check style
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- uses: astral-sh/ruff-action@v3
- uses: astral-sh/ruff-action@v3
with:
args: "format --diff"

test:
needs: style
strategy:
matrix:
os: [ubuntu-24.04, windows-2022, macos-15]
python-version: ['3.10', '3.13']
name: Run tests (Python ${{ matrix.python-version }} on ${{ matrix.os }})
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v5
- name: Set up Python ${{ matrix.python-version }}
run: uv python install ${{ matrix.python-version }}
- name: Run tests
run: uv run --extra cibw pytest --cov=sleepecg tests
4 changes: 3 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ full = [ # complete package functionality
"joblib >= 1.4.2",
"matplotlib >= 3.9.2",
"numba >= 0.61.0",
"tensorflow >= 2.17.0; python_version < '3.13'",
"tensorflow >= 2.16.2; python_version < '3.13'",
"wfdb >= 4.2.0",
]

Expand All @@ -64,6 +64,8 @@ doc = [ # RTD uses this when building the documentation
cibw = [ # cibuildwheel uses this for running the test suite
"edfio >= 0.4.4",
"numba >= 0.61.0",
"pytest >= 6.2.0",
"pytest-cov >= 6.0.0",
"wfdb >= 4.2.0",
]

Expand Down
Loading