Test plugin #508
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: Test plugin | |
on: | |
schedule: | |
# runs once a week | |
# - cron: '0 6 * * 0' | |
# runs every day | |
- cron: '0 12 * * *' | |
push: | |
branches: [ "master", "try_ci-1" ] | |
pull_request: | |
branches: [ "master" ] | |
permissions: | |
contents: read | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Pull qgis image | |
run: docker pull qgis/qgis:stable | |
- name: Pip install | |
run: | | |
docker run --name qgis_container --volume $(pwd):/app -w=/app qgis/qgis:stable sh -c "python3 -m pip install -r requirements_dev.txt --break-system-packages" | |
docker commit qgis_container qgis_with_deps | |
- name: Debug - List directory | |
run: docker run --volume $(pwd):/app -w=/app qgis_with_deps sh -c "ls -la /app" | |
- name: Debug - Print PYTHONPATH | |
run: docker run --volume $(pwd):/app -w=/app qgis_with_deps sh -c "echo \$PYTHONPATH" | |
- name: Run tests | |
run: | | |
docker run --volume $(pwd):/app -w=/app qgis_with_deps sh -c " | |
export PYTHONPATH=\$PYTHONPATH:/app && \ | |
xvfb-run -s '+extension GLX -screen 0 1024x768x24' python3 -m pytest tests -s | |
" |