-
Notifications
You must be signed in to change notification settings - Fork 0
52 lines (43 loc) · 1.09 KB
/
ci-unittest.yml
File metadata and controls
52 lines (43 loc) · 1.09 KB
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: "CI: Unit Tests"
run-name: "Tests: ${{ github.ref_name }}"
on:
push:
branches:
- main
- develop
- 'feature/**'
pull_request:
branches:
- main
- develop
jobs:
test:
name: Run Unit Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.13'
- name: Install uv
uses: astral-sh/setup-uv@v7
- name: Install dependencies
run: |
uv sync --all-extras
- name: Run tests with coverage
run: |
uv run pytest tests/unit -v --tb=short --cov=core --cov=api --cov-report=term-missing --cov-report=xml
- name: Upload coverage to GitHub Artifacts
uses: actions/upload-artifact@v5
with:
name: coverage-report
path: coverage.xml
retention-days: 30
if: always()
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.xml
fail_ci_if_error: false