File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : CI
2+
3+ on :
4+ push :
5+ branches : ["**"]
6+ pull_request :
7+
8+ jobs :
9+ lint :
10+ name : Lint (ruff + black)
11+ runs-on : ubuntu-latest
12+ steps :
13+ - uses : actions/checkout@v4
14+
15+ - name : Set up Python
16+ uses : actions/setup-python@v5
17+ with :
18+ python-version : " 3.11"
19+
20+ - name : Install dev tools
21+ run : |
22+ python -m pip install --upgrade pip
23+ pip install -r requirements-dev.txt
24+
25+ - name : Ruff (lint)
26+ run : ruff check .
27+
28+ - name : Black (format check)
29+ run : black --check --diff .
30+
31+ test :
32+ name : Tests (pytest)
33+ runs-on : ubuntu-latest
34+ needs : lint
35+ strategy :
36+ matrix :
37+ python-version : ["3.10", "3.11", "3.12"]
38+ steps :
39+ - uses : actions/checkout@v4
40+
41+ - name : Set up Python ${{ matrix.python-version }}
42+ uses : actions/setup-python@v5
43+ with :
44+ python-version : ${{ matrix.python-version }}
45+
46+ - name : Cache pip
47+ uses : actions/cache@v4
48+ with :
49+ path : ~/.cache/pip
50+ key : ${{ runner.os }}-pip-${{ hashFiles('requirements.txt') }}
51+ restore-keys : |
52+ ${{ runner.os }}-pip-
53+
54+ - name : Install deps
55+ run : |
56+ python -m pip install --upgrade pip
57+ pip install -r requirements.txt;
58+ - name : Run pytest
59+ run : pytest -q
Original file line number Diff line number Diff line change 1+ [tool .black ]
2+ line-length = 100
3+ target-version = [" py311" ]
4+
5+ [tool .ruff ]
6+ line-length = 100
7+ target-version = " py311"
8+ exclude = [
9+ " .git" ,
10+ " .venv" ,
11+ " venv" ,
12+ " env" ,
13+ " __pycache__" ,
14+ " build" ,
15+ " dist"
16+ ]
17+
18+ [tool .ruff .lint ]
19+ select = [" E" , " F" , " I" ]
20+ ignore = []
Original file line number Diff line number Diff line change 1+ [pytest]
2+ addopts = -q
3+ testpaths = tests
4+ python_files = test_*.py
Original file line number Diff line number Diff line change 11# write required libraries.
2- jupyterlab == 4.4.6
2+ jupyterlab == 4.4.6
3+ pytest == 8.4.1
Original file line number Diff line number Diff line change 1+ def test_smoke ():
2+ assert 1 + 1 == 2
You can’t perform that action at this time.
0 commit comments