forked from DataDog/integrations-extras
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
105 lines (99 loc) · 2.93 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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
dist: xenial
sudo: required
services:
- docker
language: python
python:
- '2.7'
cache:
directories:
- "$HOME/.cache/pip"
git:
depth: 3
branches:
only:
- master
env:
global:
- SKIP_CLEANUP=true
- PIP_CACHE=$HOME/.cache/pip
stages:
- name: test_pr
if: ((type = pull_request) AND (NOT commit_message =~ /ci run all/))
- name: test
if: ((branch = master) AND (type != pull_request)) OR ((commit_message =~ /ci run all/) AND (type = pull_request))
script:
# This is the default script section that will be run for every 'test' stage
- ddev validate manifest -i
- ddev validate config
- ddev validate service-checks
- ddev validate metadata ${CHECK}
- if [ -n "$PYTHON3" ]; then ddev validate py3 ${CHECK}; fi
- travis_retry ddev test --cov ${CHECK}
- ddev test ${CHECK} --bench || true
# Conditional jobs are currently buggy and verbose.
#
# https://github.com/travis-ci/beta-features/issues/28
# https://github.com/travis-ci/beta-features/issues/40
# https://github.com/travis-ci/travis-ci/issues/8295
# https://github.com/travis-ci/travis-conditions/pull/1
# https://github.com/travis-ci/travis-ci/issues/6652
jobs:
fast_finish: true
include:
- stage: test_pr
script:
- ddev validate manifest -i
- ddev validate config
- ddev validate service-checks
- ddev validate metadata
# with no params, ddev will only test integrations that are part of the branch diff
- ddev test --cov
- ddev test --bench || true
- stage: test
env: CHECK=aqua PYTHON3=true
- stage: test
env: CHECK=bind9 PYTHON3=true
- stage: test
env: CHECK=eventstore PYTHON3=true
- stage: test
env: CHECK=filebeat PYTHON3=true
- stage: test
env: CHECK=gnatsd PYTHON3=true
- stage: test
env: CHECK=gnatsd_streaming PYTHON3=true
- stage: test
env: CHECK=logstash PYTHON3=true
- stage: test
env: CHECK=neo4j PYTHON3=true
- stage: test
env: CHECK=nextcloud PYTHON3=true
- stage: test
env: CHECK=reboot_required PYTHON3=true
- stage: test
env: CHECK=redis_sentinel PYTHON3=true
- stage: test
env: CHECK=riak_repl PYTHON3=true
- stage: test
env: CHECK=snmpwalk PYTHON3=true
- stage: test
env: CHECK=sortdb PYTHON3=true
- stage: test
env: CHECK=stardog PYTHON3=true
- stage: test
env: CHECK=storm PYTHON3=true
- stage: test
env: CHECK=traefik PYTHON3=true
- stage: test
env: CHECK=upsc PYTHON3=true
before_install:
- PATH="$(pyenv root)/versions/3.7.1/bin:$PATH:$(pyenv root)/versions/3.6.7/bin"
install:
- pip install -U pip setuptools codecov
- pip install -r requirements-dev.txt
- ddev config set extras .
- ddev config set repo extras
# we should clean generated files before we save the cache
# We don't want to save .pyc files, so we'll use find and -delete
before_cache:
- find $HOME/.cache/pip -name *.pyc -delete