@@ -2,48 +2,39 @@ name: CI/CD Pipeline
22
33on :
44 push :
5- branches : [ master, release ]
5+ branches : [master, release]
66 pull_request :
7- branches : [ master ]
7+ branches : [master]
88 release :
9- types : [ published ]
9+ types : [published]
1010
1111env :
1212 REGISTRY : ghcr.io
1313 IMAGE_NAME : ${{ github.repository }}
1414
1515jobs :
1616 lint :
17- name : Code Style & Linting
17+ name : Lint
1818 runs-on : ubuntu-latest
1919 steps :
20- - name : Checkout code
21- uses : actions/checkout@v4
20+ - uses : actions/checkout@v4
2221
23- - name : Set up Python
24- uses : actions/setup-python@v5
22+ - uses : actions/setup-python@v5
2523 with :
26- python-version : ' 3.12'
27-
28- - name : Create virtual environment
29- run : python -m venv venv
24+ python-version : " 3.12"
3025
3126 - name : Install dependencies
3227 run : |
33- source venv/bin/activate
34- pip install --upgrade pip
35- pip install black flake8
36- pip install -e .
28+ pip install \
29+ "git+https://github.com/vicentebolea/vtk-knowledge" \
30+ "git+https://github.com/vicentebolea/vtk-validate"
31+ pip install -e ".[dev]"
3732
38- - name : Run Black
39- run : |
40- source venv/bin/activate
41- black --check --diff src/ tests/
33+ - name : ruff lint
34+ run : ruff check src/vtk_mcp/
4235
43- - name : Run Flake8
44- run : |
45- source venv/bin/activate
46- flake8 src/
36+ - name : ruff format check
37+ run : ruff format --check src/vtk_mcp/
4738
4839 actionlint :
4940 runs-on : ubuntu-latest
@@ -52,53 +43,56 @@ jobs:
5243
5344 - name : Install actionlint
5445 run : |
55- # Download and install actionlint
5646 bash <(curl https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash)
5747 echo "${PWD}" >> "$GITHUB_PATH"
5848
5949 - name : Run actionlint
6050 run : actionlint
6151
6252 test :
63- name : Run Tests
53+ name : Test (Python ${{ matrix.python-version }})
6454 runs-on : ubuntu-latest
6555 needs : [lint, actionlint]
6656 strategy :
6757 matrix :
68- python-version : [' 3.10', ' 3.11', ' 3.12' ]
58+ python-version : [" 3.10", " 3.11", " 3.12" ]
6959
7060 steps :
71- - name : Checkout code
72- uses : actions/checkout@v4
61+ - uses : actions/checkout@v4
7362
74- - name : Set up Python ${{ matrix.python-version }}
75- uses : actions/setup-python@v5
63+ - uses : actions/setup-python@v5
7664 with :
7765 python-version : ${{ matrix.python-version }}
7866
79- - name : Create virtual environment
80- run : python -m venv venv
81-
8267 - name : Install dependencies
8368 run : |
84- source venv/bin/activate
85- pip install --upgrade pip
86- pip install -e ".[test]"
69+ pip install \
70+ "git+https://github.com/vicentebolea/vtk-knowledge" \
71+ "git+https://github.com/vicentebolea/vtk-validate"
72+ pip install -e ".[dev]"
8773
8874 - name : Run unit tests
89- run : |
90- source venv/bin/activate
91- pytest -m unit -v
75+ run : pytest -m unit -v
9276
9377 - name : Run client tests
94- run : |
95- source venv/bin/activate
96- pytest tests/test_client_no_server.py -v
78+ run : pytest tests/test_client_no_server.py -v
9779
9880 - name : Run integration tests
99- run : |
100- source venv/bin/activate
101- pytest -m integration -v
81+ run : pytest -m integration -v
82+
83+ uv-smoke :
84+ name : uv smoke test
85+ runs-on : ubuntu-latest
86+ steps :
87+ - uses : actions/checkout@v4
88+
89+ - uses : astral-sh/setup-uv@v5
90+
91+ - name : uv sync resolves all dependencies
92+ run : uv sync --extra dev
93+
94+ - name : Import check
95+ run : uv run python -c "from vtk_mcp.config import Settings; Settings()"
10296
10397 docker-deploy :
10498 name : Build and Push Deployment Image
@@ -109,8 +103,7 @@ jobs:
109103 contents : read
110104 packages : write
111105 steps :
112- - name : Checkout code
113- uses : actions/checkout@v4
106+ - uses : actions/checkout@v4
114107 with :
115108 submodules : recursive
116109
0 commit comments