-
Notifications
You must be signed in to change notification settings - Fork 0
63 lines (51 loc) · 1.67 KB
/
ci.yml
File metadata and controls
63 lines (51 loc) · 1.67 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
57
58
59
60
61
62
63
name: CI
on:
push:
branches: ["**"]
pull_request:
branches: ["**"]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install system dependencies (Qt/EGL for Linux)
run: |
sudo apt-get update
sudo apt-get install -y \
qtbase5-dev \
libxcb-xinerama0 \
libxcb-icccm4 \
libxcb-image0 \
libxcb-keysyms1 \
libxcb-render-util0 \
libxkbcommon-x11-0 \
xvfb
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install -r requirements-dev.txt
- name: Lint (ruff)
run: ruff check . || true
- name: Format check (black)
run: black --check .
- name: Security scan (bandit)
run: bandit -r . -f json -o security-results.json || true
- name: Dependency vulnerability check (safety)
run: safety check --json || true
- name: Code quality (flake8)
run: flake8 . --max-line-length=100 --extend-ignore=E203,W503 || true
- name: Run tests with coverage
env:
PYTHONPATH: ${{ github.workspace }}
run: xvfb-run -a pytest --cov=. --cov-report=xml --cov-report=html --ignore=tests/frontend/test_tool_registry.py --ignore=tests/frontend/test_app.py --ignore=tests/test_osnap.py
- name: Upload coverage reports
uses: codecov/codecov-action@v4
with:
file: ./coverage.xml