Skip to content

Commit ca78f9a

Browse files
committed
Added test workflow
1 parent 564ae3b commit ca78f9a

File tree

2 files changed

+36
-0
lines changed

2 files changed

+36
-0
lines changed

.github/workflows/test.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: Test
2+
on:
3+
pull_request:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
test:
10+
name: Test
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- name: 🛎 Checkout
15+
uses: actions/checkout@v4
16+
with:
17+
ref: ${{ github.head_ref }}
18+
19+
- name: 🔭 Install UV
20+
uses: astral-sh/setup-uv@v6
21+
with:
22+
enable-cache: true
23+
cache-dependency-glob: "**/pyproject.toml"
24+
25+
- name: 🐍 Setup Python
26+
uses: actions/setup-python@v5
27+
with:
28+
python-version: "3.13"
29+
30+
- name: 📦 Install Hatch
31+
uses: pypa/hatch@install
32+
33+
- name: 🧪 Type Tests
34+
run: hatch run

pyproject.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,8 @@ exe = "pyinstaller.exe ephys_link.spec -y -- -d && pyinstaller.exe ephys_link.sp
7171
exe-clean = "pyinstaller.exe ephys_link.spec -y --clean"
7272
check = "basedpyright"
7373
check-watched = "basedpyright --watch"
74+
tests = "pytest"
75+
cov = "pytest --cov=ephys_link --cov-report=html --cov-report=term-missing"
7476

7577
[tool.hatch.envs.docs]
7678
installer = "uv"

0 commit comments

Comments
 (0)