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

Add testing against NumPy nightlies #643

Draft
wants to merge 4 commits into
base: master
Choose a base branch
from
Draft
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
41 changes: 32 additions & 9 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,7 @@ concurrency:

jobs:
test:
# name: Test / ${{ matrix.platform }} / Nightly ${{ matrix.nightly[0] }} / Python ${{ matrix.python-version }}
name: Test / ${{ matrix.platform }} / Python ${{ matrix.python-version }}
name: Regular tests / ${{ matrix.platform }} / Python ${{ matrix.python-version }}
runs-on: ${{ matrix.platform }}
strategy:
fail-fast: false
Expand All @@ -40,12 +39,36 @@ jobs:
allow-prereleases: true
- uses: yezz123/setup-uv@v4

- name: Run CPython tests
if: ${{ !startsWith(matrix.python-version, 'pypy') }}
# run: uvx nox -s ${{ matrix.nightly[1] }}tests
# On PyPy, we skip SciPy because we don't have wheels
# available, see noxfile.py for more details.
- name: Run tests
run: uvx nox -s tests

- name: Run PyPy tests
if: ${{ startsWith(matrix.python-version, 'pypy') }}
# run: uvx nox -s ${{ matrix.nightly[1] }}tests
run: uvx nox -s tests
# In this job, we test against the NumPy nightly wheels hosted on
# https://anaconda.org/scientific-python-nightly-wheels/numpy
# on the latest Python version available across platforms, instead of
# testing all Python versions and implementations on all platforms.
# We do not test on PyPy.
#
# However, "nox -s nightly-tests" can be used locally anywhere, on
# any Python version and implementation on any platform and we leave
# it to the user to decide what Python version to test against, which
# might or might not have a corresponding NumPy nightly wheel present.
nightlies:
name: Nightly tests / ${{ matrix.platform }} / Python ${{ matrix.python-version }}
runs-on: ${{ matrix.platform }}
strategy:
fail-fast: false
matrix:
platform: [ubuntu-latest, macos-13, macos-latest, windows-latest]
python-version: ["3.x"]

steps:
- uses: actions/checkout@v4.1.7
- uses: actions/setup-python@v5.1.1
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
- uses: yezz123/setup-uv@v4
- name: Run tests against nightly wheels for NumPy and SciPy
run: uvx nox -s nightly-tests
Loading