-
Notifications
You must be signed in to change notification settings - Fork 5
56 lines (47 loc) · 1.34 KB
/
Copy pathpython.yml
File metadata and controls
56 lines (47 loc) · 1.34 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
# This workflow will build a golang project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go
name: Python
on:
push:
branches: [ "main" ]
paths:
- "src/**"
- "tests/**"
- ".github/**"
- "g4/**"
- "pyproject.toml"
pull_request:
branches: [ "main" ]
paths:
- "src/**"
- "tests/**"
- ".github/**"
- "g4/**"
- "pyproject.toml"
jobs:
python:
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
python-version: ['3.11', '3.12', '3.13']
steps:
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
- name: Set up Python 3
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
uses: astral-sh/setup-uv@4959332f0f014c5280e7eac8b70c90cb574c9f9b # v6
with:
enable-cache: true
- name: Set up Python 3
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
uv sync --all-extras --dev
- name: "Run unit tests"
run: |
uv run pytest -vs