Skip to content

Update README.md

Update README.md #73

Workflow file for this run

name: Django CI Tests
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
strategy:
max-parallel: 4
matrix:
python-version: [
3.8,
#3.9
]
services:
db:
image: postgis/postgis:14-3.3
env:
POSTGRES_USER: optimeta
POSTGRES_PASSWORD: optimeta
POSTGRES_DB: optimetaPortal
ports:
- 5432:5432
options: --mount type=tmpfs,destination=/var/lib/postgresql/data --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
steps:
- uses: actions/checkout@v3
- name: Install Chromium
run: |
sudo apt install -y chromium-browser chromium-chromedriver
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install GDAL from UbuntuGIS
run: |
sudo apt-get update
sudo add-apt-repository ppa:ubuntugis/ppa
sudo apt-get install -y -qq gdal-bin libgdal-dev python3-gdal
- name: Install Python Dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install -r requirements-dev.txt
- name: Run Django migrations
run: |
python manage.py makemigrations
python manage.py migrate
- name: Run Tests
run: |
python -Wa manage.py test tests
- name: Run UI Tests
run: |
python -Wa manage.py runserver > server.log 2>&1 & python -Wa manage.py test tests-ui
- name: Print Server Logs
run: |
cat server.log
# pwd
# tree .
- name: Upload screenshots
if: always()
uses: actions/upload-artifact@v2
with:
name: screenshots for Python ${{ matrix.python-version }}
path: |
${{ github.workspace }}/tests-ui/screenshots/