Bump actions/setup-python from 4 to 5 #170
Workflow file for this run
This file contains 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: "🎳 Tester" | |
on: | |
push: | |
branches: [main] | |
paths: | |
- "**.py" | |
- .github/workflows/tester.yml | |
pull_request: | |
branches: [main] | |
paths: | |
- "**.py" | |
- .github/workflows/tester.yml | |
env: | |
PROJECT_FOLDER: "qtribu" | |
PYTHON_VERSION: 3.9 | |
jobs: | |
tests-unit: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Get source code | |
uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ env.PYTHON_VERSION }} | |
cache: "pip" | |
cache-dependency-path: "requirements/testing.txt" | |
- name: Install Python requirements | |
run: | | |
python -m pip install -U pip setuptools wheel | |
python -m pip install -U -r requirements/testing.txt | |
- name: Run Unit tests | |
run: pytest tests/unit/ | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 | |
test-qgis: | |
runs-on: ubuntu-latest | |
container: | |
image: qgis/qgis:release-3_28 | |
env: | |
CI: true | |
DISPLAY: ":1" | |
MUTE_LOGS: true | |
NO_MODALS: 1 | |
PYTHONPATH: "/usr/share/qgis/python/plugins:/usr/share/qgis/python:." | |
WITH_PYTHON_PEP: false | |
options: -v /tmp/.X11-unix:/tmp/.X11-unix -v ${{ github.workspace }}:/tests_directory | |
steps: | |
- name: Get source code | |
uses: actions/checkout@v4 | |
- name: Print QGIS version | |
run: qgis --version | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ env.PYTHON_VERSION }} | |
cache: "pip" | |
cache-dependency-path: "requirements/testing.txt" | |
- name: Install Python requirements | |
run: | | |
python3 -m pip install -U pip setuptools wheel | |
python3 -m pip install -U -r requirements/testing.txt | |
- name: Run Unit tests | |
run: pytest tests/qgis/ | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 |