forked from mercury-telemetry/mercury-telemetry
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
92 lines (72 loc) · 2.51 KB
/
.travis.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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
language: python
os: linux
dist: bionic
jobs:
include:
- name: "Python 3.8 on Bionic Linux"
os: linux
dist: bionic
python: 3.8
services:
- xvfb
- docker
- postgresql
addons:
firefox: latest
before_install:
- wget https://github.com/mozilla/geckodriver/releases/download/v0.26.0/geckodriver-v0.26.0-linux64.tar.gz
- mkdir geckodriver
- tar -xzf geckodriver-v0.26.0-linux64.tar.gz -C geckodriver
- export PATH=$PATH:$PWD/geckodriver
- docker pull grafana/grafana
- docker run -d -p 3000:3000 grafana/grafana
- docker ps -a
install:
- pip3 install --upgrade pip
- pip3 install -r requirements.txt
- pip3 install -r test-requirements.txt
before_script:
- psql -c 'create database mercury;' -U postgres
- python3 manage.py migrate
- python3 manage.py collectstatic --noinput
script:
- black --check --diff .
- flake8 . # modify .flake8 env file to update flake8 configuration
- coverage run manage.py test # modify .coveragerc env file to update test configuration
after_script:
- coveralls
- cat geckodriver.log
- name: "Python 3.7 on macOS"
os: osx
osx_image: xcode11.3
language: shell
addons:
homebrew:
packages:
- geckodriver
- grafana
casks:
- firefox
update: true
before_install:
- brew services start grafana
# The following lines set up PostgreSQL on macOS worker
- export PG_DATA=$(brew --prefix)/var/postgres
- pg_ctl -w start -l postgres.log --pgdata ${PG_DATA}
- createuser -s postgres
- cat postgres.log
install:
- pip3 install --upgrade pip
- pip3 install -r requirements.txt
- pip3 install -r test-requirements.txt
before_script:
- psql -c 'create database mercury;' -U postgres
- python3 manage.py migrate
- python3 manage.py collectstatic --noinput
script:
- black --check --diff .
- flake8 . # modify .flake8 env file to update flake8 configuration
- coverage run manage.py test # modify .coveragerc env file to update test configuration
after_script:
- coveralls
- cat geckodriver.log