-
Notifications
You must be signed in to change notification settings - Fork 3
65 lines (58 loc) · 1.81 KB
/
codecov.yml
File metadata and controls
65 lines (58 loc) · 1.81 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
53
54
55
56
57
58
59
60
61
62
63
64
65
name: Codecov
permissions: {}
on:
workflow_dispatch:
push:
branches: ["main"]
paths-ignore:
- "docs/**"
- "**/*.md"
- "mkdocs.yml"
pull_request:
paths-ignore:
- "docs/**"
- "**/*.md"
- "mkdocs.yml"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
analyze:
name: Analyze
environment: codecov
permissions:
pull-requests: write # Required for bot comments
runs-on: "ubuntu-latest"
env:
PYTHONIOENCODING: utf-8
steps:
- name: Checkout code
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
persist-credentials: false
- name: Setup git user config
run: |
git config --global user.name placeholder
git config --global user.email placeholder@example.com
- name: Set up uv
uses: astral-sh/setup-uv@3259c6206f993105e3a61b142c2d97bf4b9ef83d # v7.1.0
with:
version: "latest"
enable-cache: true
python-version: "3.13"
- name: Run pytest
uses: pavelzw/pytest-action@510c5e90c360a185039bea56ce8b3e7e51a16507 # v2.2.0
with:
emoji: false
custom-pytest: uv run --frozen pytest
custom-arguments: --cov --cov-report=xml --junitxml=junit.xml -o junit_family=legacy
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@5a1091511ad55cbe89839c7260b706298ca349f7 # v5.5.1
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true
- name: Upload test results to Codecov
uses: codecov/test-results-action@47f89e9acb64b76debcd5ea40642d25a4adced9f # v1.1.1
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true