Skip to content

👷🏽 CI/CD Process #1

👷🏽 CI/CD Process

👷🏽 CI/CD Process #1

Workflow file for this run

name: Example workflow for Codecov
on: [pull_request]
jobs:
run:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
env:
OS: ${{ matrix.os }}
PYTHON: '3.12'
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest
pip install pytest-cov
- name: Generate coverage report
run: |
pytest \
--cov-report term-missing \
--cov-report xml:cov.xml \
--cov pyslurmtq
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
directory: ./coverage/reports/
env_vars: OS,PYTHON
fail_ci_if_error: true
files: cov.xml
flags: unittests
name: codecov-umbrella
verbose: true