forked from MichaelGrupp/evo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
51 lines (44 loc) · 1.19 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
os:
- linux
dist: xenial
sudo: required
services: docker
language: python
python:
- "3.5"
- "3.6"
- "3.7"
# Python for Mac is not yet officially supported by Travis.
# We test only Python 3.7 on macOS for now with a custom setup script.
# Python 2.7 is required for ROS, so this is tested in the ROS Dockerfile.
matrix:
include:
- os: osx
language: generic
env: PYTHON=3.7.0
- os: linux
language: python
env:
- EVO_DOCKERFILE="Dockerfile.rosmelodic"
- EVO_DOCKER_IMAGE="evoslam/evopython:rosmelodic"
before_install:
- bash .ci/mac-os_before_install.sh
install:
- |
if [ -z $EVO_DOCKERFILE ]; then
source .ci/set_pip_name.sh;
${pip} install . --upgrade;
evo_config set plot_backend Agg; # no X server
fi
script:
- |
if [ -z $EVO_DOCKERFILE ]; then
${pip} install pytest --upgrade;
pytest -sv;
else
docker build . --file $EVO_DOCKERFILE --tag $EVO_DOCKER_IMAGE || exit 1
if [[ $TRAVIS_BRANCH == "master" ]] && [[ $TRAVIS_PULL_REQUEST == "false" ]]; then
echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin
docker push $EVO_DOCKER_IMAGE
fi
fi