-
Notifications
You must be signed in to change notification settings - Fork 21
/
.travis.yml
33 lines (28 loc) · 899 Bytes
/
.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
dist: trusty
sudo: false
language: python
cache: pip
python:
- "3.6"
notifications:
slack: 'i-machine-think.slack.com:Gckgwf2l93LZo9tI6LZJ4UL8'
# command to install dependencies
install:
- pip install -U pip
- pip -q install -r requirements.txt
# dev dependencies
- pip install flake8
- pip install coverage
# command to run tests
before_script:
# Syntax Checks
# stop the build if there are Python syntax errors or undefined names
- time flake8 . --count --select=E901,E999,F821,F822,F823 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
- time flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
script:
# Unit test
- python -m unittest discover -v
- coverage run -m unittest discover
- coverage report --skip-covered --omit '*/virtualenv/*'
- sh integration_test.sh