chore(ci): bump actions/cache from 3.3.1 to 3.3.2 #282
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI - Test package | |
concurrency: | |
cancel-in-progress: true | |
group: ${{ github.workflow }}-${{ github.head_ref || github.ref_name }} | |
on: | |
push: | |
branches: [main] | |
paths: [pyproject.toml, incipyt/**, tests/**, .github/workflows/test.yml] | |
pull_request: | |
branches: [main] | |
types: [opened, reopened, synchronize, ready_for_review, unlocked] | |
paths: [pyproject.toml, incipyt/**, tests/**, .github/workflows/test.yml] | |
jobs: | |
lint: | |
name: Pre-commit (include linter) | |
runs-on: ubuntu-latest | |
if: github.event.pull_request.draft == false | |
steps: | |
- name: Checkout | |
uses: actions/[email protected] | |
- name: Set up Python | |
uses: actions/[email protected] | |
with: | |
cache: pip | |
cache-dependency-path: pyproject.toml | |
check-latest: true | |
python-version: 3.11 | |
- name: Install deps | |
env: | |
PIP_UPGRADE: True | |
PIP_UPGRADE_STRATEGY: eager | |
run: python -m pip install -e ".[dev]" | |
- name: Pre-commit cache | |
uses: actions/[email protected] | |
with: | |
key: ${{ hashFiles('.pre-commit-config.yaml') }} | |
path: ~/.cache/pre-commit | |
- name: Run pre-commit on all files | |
run: pre-commit run --all-files | |
test: | |
name: Tests | |
needs: lint | |
strategy: | |
matrix: | |
os: [ubuntu-latest, macos-latest, windows-latest] | |
python-version: ['3.8', '3.9', '3.10', '3.11'] | |
fail-fast: false | |
runs-on: ${{ matrix.os }} | |
env: | |
_OS: ${{ matrix.os }} | |
_PY: ${{ matrix.python-version }} | |
steps: | |
- name: Checkout | |
uses: actions/[email protected] | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/[email protected] | |
with: | |
cache: pip | |
cache-dependency-path: pyproject.toml | |
check-latest: true | |
python-version: ${{ matrix.python-version }} | |
- name: Install deps | |
env: | |
PIP_UPGRADE: True | |
PIP_UPGRADE_STRATEGY: eager | |
run: python -m pip install -e ".[test]" | |
- name: Run tests with pytest | |
run: pytest -v --cov=incipyt --cov-report=xml | |
- name: Upload coverage to Codecov | |
uses: codecov/[email protected] | |
with: | |
fail_ci_if_error: true | |
env_vars: _OS,_PY | |
version: v0.4.1 |