-
Notifications
You must be signed in to change notification settings - Fork 1
44 lines (39 loc) · 1.24 KB
/
pythonapp.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
name: FVH Feedback Map CI
on: [push]
jobs:
build:
runs-on: ubuntu-latest
services:
postgres:
image: postgis/postgis
env:
POSTGRES_DB: feedback_map_dev
POSTGRES_USER: postgres
POSTGRES_PASSWORD: feedback_map
ports:
- 5432:5432
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
steps:
- uses: actions/checkout@v1
- name: Set up Python 3.11
uses: actions/setup-python@v1
with:
python-version: 3.11
- name: Install dependencies
run: |
sudo apt-get install gdal-bin
python -m pip install --upgrade pip
pip install pipenv
cd django_server; pipenv install --system --deploy
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
cd django_server
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --statistics
- name: Test
run: |
cd django_server
coverage run --source='.' manage.py test
coverage report