@@ -17,26 +17,34 @@ jobs:
1717
1818 steps :
1919 - uses : actions/checkout@v4
20+
2021 - name : Set up Python ${{ matrix.python-version }}
2122 uses : actions/setup-python@v3
2223 with :
2324 python-version : ${{ matrix.python-version }}
2425
25- - name : Install xvfb
26- run : sudo apt-get install -y xvfb
26+ - name : Install system dependencies for X11
27+ run : |
28+ sudo apt-get update
29+ sudo apt-get install -y xvfb
30+
31+ - name : Install uv
32+ run : |
33+ curl -LsSf https://astral.sh/uv/install.sh | sh
34+ echo "${HOME}/.cargo/bin" >> $GITHUB_PATH
2735
28- - name : Install dependencies
36+ - name : Create virtual environment and install dependencies
2937 run : |
30- python -m pip install --upgrade pip
31- python -m pip install flake8 pytest
32- python -m pip install .[dev]
33- if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
38+ uv venv
39+ uv pip install -e .[dev]
40+ if [ -f requirements.txt ]; then uv pip install -r requirements.txt; fi
41+ uv pip install flake8 pytest pytest-cov
3442
3543 - name : Lint with flake8
3644 run : |
37- flake8 drone_base/ --count --select=E9,F63,F7,F82 --show-source --statistics
38- flake8 drone_base/ --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
45+ uv run flake8 drone_base/ --count --select=E9,F63,F7,F82 --show-source --statistics
46+ uv run flake8 drone_base/ --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
3947
4048 - name : Run tests with pytest and coverage
4149 run : |
42- xvfb-run -a pytest --cov=drone_base --cov-report=xml
50+ xvfb-run -a uv run pytest --cov=drone_base --cov-report=xml
0 commit comments