Skip to content

Bump the actions-version group with 2 updates #831

Bump the actions-version group with 2 updates

Bump the actions-version group with 2 updates #831

Workflow file for this run

name: Run Unit Tests
on:
# trigger on pull requests
pull_request:
# trigger on all commits to main
push:
branches:
- 'main'
# trigger on request
workflow_dispatch:
concurrency:
group: "${{ github.workflow }}-${{ github.ref }}"
cancel-in-progress: true
jobs:
test:
name: test (${{ matrix.os }}, ${{ matrix.python }}, ${{ matrix.dependencies }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
python: ['3.8', '3.9', '3.10', '3.11', '3.12']
# Unused key to force creation of new entries in the matrix
default: ['true']
include:
# Defaults to newest dependencies
- dependencies: 'newest'
# Oldest dependency tests
- python: '3.8'
dependencies: 'oldest'
- python: '3.9'
dependencies: 'oldest'
- os: 'macos-latest'
python: '3.8'
dependencies: 'oldest'
- os: 'windows-latest'
python: '3.8'
dependencies: 'oldest'
# Newest version tests for non-Linux OS
- os: 'ubuntu-latest'
python: '3.12'
dependencies: 'newest'
- os: 'macos-latest'
python: '3.12'
dependencies: 'newest'
- os: 'windows-latest'
python: '3.12'
dependencies: 'newest'
# Minimal dependencies tests
- default: 'false'
os: 'ubuntu-latest'
python: '3.12'
dependencies: 'minimal'
- os: 'macos-14'
python: '3.12'
dependencies: 'minimal'
- os: 'windows-latest'
python: '3.12'
dependencies: 'minimal'
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Python ${{ matrix.python }}
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
with:
python-version: ${{ matrix.python }}
- name: Install newest dependencies
run: |
pip install -r requirements/requirements-test.txt
pip install -r requirements/requirements-test-optional.txt
if: ${{ matrix.dependencies == 'newest' }}
- name: Install minimal dependencies
run: |
pip install -r requirements/requirements-test.txt
if: ${{ matrix.dependencies == 'minimal' }}
- name: Install oldest supported dependencies
# To prevent Dependabot from updating the pinnings in this "oldest"
# dependency list, we have to avoid the word "requirements" in the
# filename. That's why it is in the .github/ directory and named "reqs"
# instead of "requirements."
run: |
pip install -r .github/workflows/ci-oldest-reqs.txt
if: ${{ matrix.dependencies == 'oldest' }}
- name: Install the package
run: |
pip install -e .
- name: Test with pytest
run: |
pytest --cov=signac --cov-config=pyproject.toml --cov-report=xml tests/ -v
- uses: codecov/codecov-action@015f24e6818733317a2da2edd6290ab26238649a # v5.0.7
with:
token: ${{ secrets.CODECOV_TOKEN }}