Skip to content

[pre-commit.ci] pre-commit autoupdate #277

[pre-commit.ci] pre-commit autoupdate

[pre-commit.ci] pre-commit autoupdate #277

Workflow file for this run

name: test plugins ⚙️
on: [push, pull_request]
env:
POSTGRESQL_PASSWORD: ${{ secrets.DatabasePassword || 'postgres' }}
jobs:
main:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
name: setup Python
with:
python-version: '3.10'
- name: Install and run PostgreSQL/PostGIS 📦
uses: huaxk/postgis-action@v1
with:
postgresql password: ${{ env.POSTGRESQL_PASSWORD }}
postgresql db: 'test'
- name: Install and run SensorThingsAPI
uses: cgs-earth/[email protected]
- name: Run pygeoapi
run: |
docker run -d -it --rm -p 5000:80 $(docker build -q .)
- name: Install requirements 📦
run: |
pip3 install https://github.com/geopython/pygeoapi/archive/refs/heads/master.zip
pip3 install -r requirements.txt
pip3 install -r requirements-dev.txt
python3 setup.py install
- name: setup test data ⚙️
run: |
gunzip < tests/data/hotosm_bdi_waterways.sql.gz | psql postgresql://postgres:${{ env.POSTGRESQL_PASSWORD }}@localhost:5432/test
- name: run unit tests ⚙️
env:
POSTGRESQL_PASSWORD: ${{ env.POSTGRESQL_PASSWORD }}
run: |
pytest tests/test_ckan_provider.py
pytest tests/test_geopandas_provider.py
pytest tests/test_postgresql_provider.py
pytest tests/test_sensorthings_edr_provider.py
pytest tests/test_sitemap_process.py
pytest tests/test_sparql_provider.py
pytest tests/test_xml_formatter.py