-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy path.gitlab-ci.yml
36 lines (33 loc) · 1.12 KB
/
.gitlab-ci.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
stages:
- test
services:
- tgaudin/postgresql-pgtap:latest
variables:
POSTGRES_HOST_AUTH_METHOD: trust
POSTGRES_PASSWORD: "tooth"
test-backend:
stage: test
when: always
image: continuumio/miniconda3:latest
variables:
PROJECT_NAME: "Test Molar"
SERVER_NAME: "localhost"
SERVER_HOST: "http://localhost"
POSTGRES_SERVER: "tgaudin-postgresql-pgtap"
POSTGRES_USER: "postgres"
POSTGRES_PASSWORD: "tooth"
before_script:
- conda create -n molar python=3.7
- source activate molar
- apt-get update
- apt-get upgrade -y
- apt-get install -y postgresql-client libxrender1
- pip install coverage pytest alembic
- pip install -e .[backend]
- pip install -e .[test]
- molarcli --data-dir db install remote --hostname tgaudin-postgresql-pgtap --postgres-username postgres --postgres-password tooth --superuser-email test@molar.tooth --superuser-password tooth
- uvicorn molar.backend.main:app --debug --log-level debug &
script:
- pytest
- coverage run --source molar -m py.test
- coverage report