-
Notifications
You must be signed in to change notification settings - Fork 0
54 lines (46 loc) · 1.04 KB
/
tests.yml
File metadata and controls
54 lines (46 loc) · 1.04 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
name: Run Tests
on:
push:
branches:
- main
paths-ignore:
- README.md
- CHANGELOG.md
- .gitignore
- examples/**
- docker/**
- images/**
- imgs/**
- docs/**
pull_request:
branches:
- main
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version:
- "3.10"
- "3.11"
- "3.12"
steps:
# Step 1: Checkout the repository
- name: Checkout code
uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v5
with:
enable-cache: true
cache-dependency-glob: "uv.lock"
- name: "Set up Python"
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
# Step 4: Install dependencies using UV
- name: Install deps
run: uv sync --locked --all-extras --dev
# Step 5: Run tests with pytest
- name: Run tests
run: uv run pytest tests