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

include multiple pytest versions in PR check #22813

Merged
merged 5 commits into from
Jan 31, 2024
Merged
Changes from 2 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
13 changes: 12 additions & 1 deletion .github/workflows/pr-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,8 @@ jobs:
# macOS runners are expensive, and we assume that Ubuntu is enough to cover the Unix case.
os: [ubuntu-latest, windows-latest]
# Run the tests on the oldest and most recent versions of Python.
python: ['3.8', '3.x', '3.12-dev']
python: ['3.8', '3.x', '3.12-dev'] # run for 3 pytest versions, most recent stable, oldest version supported and pre-release
eleanorjboyd marked this conversation as resolved.
Show resolved Hide resolved
pytest-version: ['pytest', 'pytest@pre-release', 'pytest==6.2.0']

steps:
- name: Checkout
Expand All @@ -107,6 +108,16 @@ jobs:
with:
python-version: ${{ matrix.python }}

- name: Install specific pytest version
if: matrix.pytest-version == 'pytest@pre-release'
run: |
python -m pip install --pre pytest

- name: Install specific pytest version
if: matrix.pytest-version != 'pytest@pre-release'
run: |
python -m pip install "${{ matrix.pytest-version }}"

eleanorjboyd marked this conversation as resolved.
Show resolved Hide resolved
- name: Install base Python requirements
uses: brettcannon/pip-secure-install@v1
with:
Expand Down
Loading