19 update readme #17
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: QGIS Color Table Tests | |
on: [push, pull_request] | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 # Action to checkout the repository | |
- name: Set up QGIS and Python | |
run: | | |
sudo add-apt-repository -y ppa:ubuntugis/ppa # Add Ubuntu GIS PPA | |
sudo apt-get update # Update package lists | |
sudo apt-get install -y qgis python3.10 python3.10-dev python3-pip # Install QGIS and Python dependencies | |
sudo apt-get install -y qgis-plugin-grass | |
python3.10 -m pip install --upgrade pip # Upgrade pip for Python 3.10 | |
python3.10 -m pip install pytest pytest-qt PyQt6 # Install testing dependencies | |
- name: Run tests # Step to run tests | |
run: | | |
export QGIS_PREFIX_PATH="/usr" # Set QGIS prefix path | |
export PYTHONPATH="/usr/share/qgis/python:$GITHUB_WORKSPACE" # Set Python path | |
export LD_LIBRARY_PATH="/usr/lib" # Set LD_LIBRARY_PATH | |
export QGIS_DEBUG=0 # Disable QGIS debugging | |
export QGIS_LOG_FILE=/dev/null # Redirect QGIS logs to /dev/null | |
pytest test/test_qgis_color_func.py # Run pytest for the specified test file |