Skip to content

Update codecov/codecov-action action to v4 (#19) #22

Update codecov/codecov-action action to v4 (#19)

Update codecov/codecov-action action to v4 (#19) #22

Workflow file for this run

name: Test
on:
push:
branches: ["main"]
pull_request:
jobs:
test:
runs-on: ubuntu-latest
env:
PIP_NO_PYTHON_VERSION_WARNING: 1
PIP_DISABLE_PIP_VERSION_CHECK: 1
strategy:
matrix:
python-version: ["3.8", "3.10", "3.12"]
steps:
- uses: actions/checkout@v4
with:
show-progress: false
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
allow-prereleases: true
python-version: ${{ matrix.python-version }}
cache: "pip"
cache-dependency-path: "requirements.txt"
- name: Install dependencies
run: "pip install -r requirements.txt"
- name: Install
run: "pip install ."
- name: Run tests
run: "pytest --cov=myloginpath test"
- uses: codecov/codecov-action@v4
- name: Build distribution
run: "python -m build ."
- name: Upload distribution
if: matrix.python-version == '3.10'
uses: actions/upload-artifact@v4
with:
name: myloginpath-dist
path: dist