forked from giovannicuriel/dojot-module-python
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
32 lines (26 loc) · 861 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
language: python
python:
- '3.6'
before_install:
- pip install -e .[dev]
- pip install codecov
services:
- docker
env:
global:
- KAFKA_HOSTS="localhost:9092"
- KAFKA_GROUP_ID="sample-travis"
- LOCALHOST_MOCK="http://localhost:5002"
- DATA_BROKER_URL=${LOCALHOST_MOCK}
- AUTH_URL=${LOCALHOST_MOCK}
- DEVICE_MANAGER_URL=${LOCALHOST_MOCK}
- PYTHONPATH=$(pwd)
script:
- docker network create kafkanet
- docker run -d --network kafkanet --publish 2181:2181 --name zookeeper zookeeper:3.4
- docker run -d --name kafka --network kafkanet --publish 9092:9092 --publish 7203:7203 --env ZOOKEEPER_IP=zookeeper --env JAVA_OPTS="-Xms256m -Xmx512" --env KAFKA_ADVERTISED_HOST_NAME=127.0.0.1 ches/kafka
- sleep 10
- python3 ./tests/dojot_monitor.py &
- pytest --cov=./dojot --cov-report=html
after_success:
- codecov