v0.3.3 #102
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: Tests | |
on: | |
push: | |
pull_request: | |
release: | |
types: [created] | |
jobs: | |
run-tests: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
cache: 'pip' | |
- name: Configure Git user | |
run: | | |
git config --local user.email "github-actions[bot]@users.noreply.github.com" | |
git config --local user.name "github-actions[bot]" | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
pip install -r requirements.tests.txt | |
pip install -r docs/requirements.txt | |
- name: Install package | |
run: | | |
pip install -e . | |
- name: Run Ruff | |
run: ruff check --output-format=github . | |
- name: Run tests with coverage | |
run: | | |
pytest --junitxml=pytest.xml --cov-report=term-missing:skip-covered --cov=projectcard tests/ | tee pytest-coverage.txt | |
- name: Pytest coverage comment | |
if: github.event_name == 'pull_request' | |
uses: MishaKav/pytest-coverage-comment@main | |
with: | |
pytest-coverage-path: ./pytest-coverage.txt | |
junitxml-path: ./pytest.xml | |
publish-docs: | |
uses: ./.github/workflows/publish-docs.yml |