ci: remove flaky codecov upload step #5
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Python Tests | |
| on: [push, pull_request] | |
| jobs: | |
| lint: | |
| 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 linting tools | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install black==23.12.1 isort==5.13.2 flake8==6.1.0 | |
| - name: Check code format (Black) | |
| run: black --check src/ tests/ | |
| - name: Check import order (isort) | |
| run: isort --check-only src/ tests/ | |
| - name: Lint with flake8 | |
| run: flake8 src/ tests/ --count --select=E9,F63,F7,F82 --show-source --statistics | |
| security: | |
| 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 security tools | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install pip-audit | |
| - name: Scan dependencies for vulnerabilities | |
| run: pip-audit -r requirements.txt | |
| tests: | |
| runs-on: ubuntu-latest | |
| needs: [lint, security] | |
| strategy: | |
| matrix: | |
| python-version: ['3.10', '3.11'] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install system dependencies (Qt offscreen) | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y --no-install-recommends \ | |
| libgl1 libglib2.0-0 libxkbcommon-x11-0 \ | |
| libdbus-1-3 libxcb-icccm4 libxcb-image0 \ | |
| libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 \ | |
| libxcb-xinerama0 libxcb-xfixes0 | |
| - name: Install Python dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -r requirements.txt | |
| pip install pytest-cov | |
| - name: Run tests | |
| env: | |
| QT_QPA_PLATFORM: offscreen | |
| run: | | |
| pytest tests/ --cov=src --cov-report=xml -v |