forked from vacanza/holidays
-
Notifications
You must be signed in to change notification settings - Fork 0
58 lines (49 loc) · 1.44 KB
/
Copy pathrun-code-tests.yml
File metadata and controls
58 lines (49 loc) · 1.44 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
name: Code tests
on:
workflow_call:
secrets:
CODECOV_TOKEN:
required: false
env:
DEFAULT_PYTHON_VERSION: '3.14'
FORCE_COLOR: 1
permissions: {}
jobs:
test:
name: Test Python ${{ matrix.python-version }} on ${{ matrix.os }}
permissions:
contents: read
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- macos-latest
- ubuntu-latest
- windows-latest
python-version:
- '3.10'
- '3.11'
- '3.12'
- '3.13'
- '3.14'
- '3.15'
steps:
- name: Check out repository
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Install uv
uses: astral-sh/setup-uv@20cfd1bf945f4377ade1205e4dbc17946fc9a30d # v10.0.1
with:
python-version: ${{ matrix.python-version }}
version-file: uv.lock
- name: Install Python ${{ matrix.python-version }}
run: uv python install ${{ matrix.python-version }}
- name: Install dependencies
run: uv sync --frozen --no-dev --group tests --link-mode=copy --no-build --no-binary-package holidays
- name: Run tests
run: make test
- name: Upload coverage to Codecov
uses: codecov/codecov-action@fb8b3582c8e4def4969c97caa2f19720cb33a72f # v7.0.0
with:
token: ${{ secrets.CODECOV_TOKEN }}