-
Notifications
You must be signed in to change notification settings - Fork 3
29 lines (29 loc) · 968 Bytes
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
name: Python
on: [push, pull_request]
jobs:
Pytest:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
- name: Install dependencies
run: |
python -m pip install --upgrade pip pytest pytest-mock pytest-cov
pip install -e .
./install_git-cinnabar.sh
echo "${{ github.workspace }}" >> $GITHUB_PATH
- name: Test with pytest
run: |
pytest --junitxml=pytest.xml --cov-report "xml:coverage.xml" --cov=git_hg_sync tests/
- name: Pytest coverage comment
uses: MishaKav/pytest-coverage-comment@main
with:
pytest-xml-coverage-path: coverage.xml
title: Unit tests Coverage
badge-title: Unit tests Coverage
junitxml-path: pytest.xml
junitxml-title: JUnit Xml Summary