-
Notifications
You must be signed in to change notification settings - Fork 1
/
.travis.yml
42 lines (37 loc) · 827 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
34
35
36
37
38
39
40
41
42
language: python
git:
depth: false
quiet: true
python:
- 2.7
- 3.5
- 3.8
stages:
- Code formatter
- Code linter
- Unit-tests
jobs:
include:
- python: 3.8
stage: Code formatter
install:
- pip install black
script:
- black .
- python: 2.7
stage: Code linter
install:
- pip install flake8
script:
- flake8 .
stage: Unit-tests
before_install:
- pip install pip-tools
- pip-compile --output-file=requirements.txt ./tests/requirements/requirements.in # Building the requirements file depending on python version
install:
- pip install -r requirements.txt
- django-admin startproject testproject .
script:
- pytest tests --cov=django_rest --cov-report=xml:.report/report.xml
after_success:
- codecov # Submitting coverage