-
Notifications
You must be signed in to change notification settings - Fork 17
/
Copy path.travis.yml
71 lines (56 loc) · 2.08 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
---
language: python
sudo: required
dist: xenial
python:
- '3.5'
- '3.6'
node_js:
- '8.12.0'
# One line per build
env:
- DJANGO_CONFIGURATION="Test" DJANGO_TEST_WITH_WEB="y" DJANGO_TEST_WITH_ES="y"
services:
- redis-server
- elasticsearch
# Run Django test sqlite db
# Prepare (install npm + pip dependencies, collect statics, locale)
install:
# OS dependencies
- sudo apt-get update -qy
- sudo apt-get install -y python-dev gettext pandoc binutils libproj-dev gdal-bin
# Python dependencies
- pip install -r requirements/dev.txt
# Frontend dependencies
- npm install
- npm run-script build
# Install NLTK models (cannot be done by requirements.txt)
- python -m nltk.downloader punkt
# Prepare django
- python manage.py collectstatic --no-input
- python manage.py compilemessages --l de --l en
# Elasticsearch needs few seconds to start
before_script:
- sleep 10
# Start tests
script:
- coverage run --branch manage.py test
- coverage report
# Generate test coverage
after_success:
- coveralls
# Deploy to staging (currently not working due to pandoc heroku bug)
#deploy:
# provider: heroku
# api_key: $HEROKU_STAGING_API_KEY
# app: $HEROKU_STAGING_APP_NAME
# run:
# - "python manage.py collectstatic --no-input"
# - "python manage.py compilemessages --l de --l en"
deploy:
provider: pypi
user: openlegaldata
password:
secure: "kCQ/I9m+qV8vpq3KyhVCwfJm1tAgtUvNiYsAS7r4emiZC9yDvesb/XI4YqJkz3b/GgJ3CJywGW//DEEQzCR5NL19qoHwSfXPFHf9emzL9og72NrH/NJxgde5JhaA6giQO8ygALP0l67/sOUAKH6c2w9Qy0t6YsdebGYnYfoUHPWULz0tSDF76+BiW1MV5AQmQjyengM5bfRczPFktre3fzeXkkX+bvscepsiAVFUpZfPyBWpIHG+dSeEmxw5YlseO8tO41eSI55lXYIA/tqmljal2n+1Owb1RTkYrIMMg1rDjEXILydUpavOiOwGvMzRhDZ/WtFaQPQrnegL/b1lUsH7EERopJC+QgNhirAjyl2q8z+LOM+nh9azcQlKohkavPz8pgmsv+SlOBk5AQZ0jTMJt06CseSRJfTmjvpuHVCIywHvDYGIY0XzOFxk6eMrnrKXIfXrEARKnpezVl/UomaRDiMc4rO9YRTXWDR91mIG9zz0uRYIMUxhvByT8i6NPqGxJZYUTL3GiPIVhWmVvsBBZ+z2ulXI91v35lafa8Heme/Y1goO8eB7+N1p7N6UrwYiWf2Dz/k5ddrtLJCgGp42IF2cKqJvUOlmovutdP1NgFhK6GxpjQf339ngdSUVhGG7lYhukN8yJdeFjp1hd4kG25oWurLkq0mGFUNmQUA="
on:
tags: true