forked from SonarOpenCommunity/sonar-cxx
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
76 lines (65 loc) · 3.1 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
language: java
dist: precise
jdk:
- oraclejdk8
env:
- SONARHOME=/tmp/sonarqube-5.6.6 SONARAPI=SqApi56
- SONARHOME=/tmp/sonarqube-6.0 SONARAPI=SqApi56
- SONARHOME=/tmp/sonarqube-6.1 SONARAPI=SqApi56
- SONARHOME=/tmp/sonarqube-6.2 SONARAPI=SqApi62
- SONARHOME=/tmp/sonarqube-6.3.1 SONARAPI=SqApi62
- SONARHOME=/tmp/sonarqube-6.4 SONARAPI=SqApi62
- SONARHOME=/tmp/sonarqube-6.5-RC2 SONARAPI=SqApi62
matrix:
fast_finish: true
# allow_failures:
# - env: SONARHOME=/tmp/sonarqube-6.5-RC2 SONARAPI=SqApi62
# shorten the VM hostname with the new workaround
# https://github.com/travis-ci/travis-ci/issues/5227#issuecomment-165131913
addons:
hosts:
- myshorthost
hostname: myshorthost
before_cache:
# remove all the artifacts that are installed in local repo because of mvn deploy
- rm -rf $HOME/.m2/repository/org/sonarsource/sonarqube-plugins/cxx
- find $HOME/.m2 -name resolver-status.properties -exec rm {} \;
cache:
directories:
- '$HOME/.m2/repository'
before_install:
- cat /etc/hosts # optionally check the content
- travis_retry sudo apt-add-repository -y ppa:boost-latest/ppa
- travis_retry sudo apt-get -qq update
- travis_retry sudo apt-get -qq install boost1.55
install:
- cd /tmp
- travis_retry wget -q https://sonarsource.bintray.com/Distribution/sonarqube/sonarqube-5.6.6.zip
- unzip -qq sonarqube-5.6.6.zip
- travis_retry wget -q https://sonarsource.bintray.com/Distribution/sonarqube/sonarqube-6.0.zip
- unzip -qq sonarqube-6.0.zip
- travis_retry wget -q https://sonarsource.bintray.com/Distribution/sonarqube/sonarqube-6.1.zip
- unzip -qq sonarqube-6.1.zip
- travis_retry wget -q https://sonarsource.bintray.com/Distribution/sonarqube/sonarqube-6.2.zip
- unzip -qq sonarqube-6.2.zip
- travis_retry wget -q https://sonarsource.bintray.com/Distribution/sonarqube/sonarqube-6.3.1.zip
- unzip -qq sonarqube-6.3.1.zip
- travis_retry wget -q https://sonarsource.bintray.com/Distribution/sonarqube/sonarqube-6.4.zip
- unzip -qq sonarqube-6.4.zip
- travis_retry wget -q https://sonarsource.bintray.com/Distribution/sonarqube/sonarqube-6.5-RC2.zip
- unzip -qq sonarqube-6.5-RC2.zip
- travis_retry wget -q https://sonarsource.bintray.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-3.0.3.778.zip
- unzip -qq sonar-scanner-cli-3.0.3.778.zip
- /tmp/sonar-scanner-3.0.3.778/bin/sonar-scanner --version
- cd -
before_script:
- travis_retry sudo pip install -q requests
- travis_retry sudo pip install -q behave
- travis_retry sudo pip install -q colorama
script:
- mvn install -DskipTests=true
- mvn test
- RAILS_ENV=production PATH=$PATH:/tmp/sonar-scanner-3.0.3.778/bin TestDataFolder=~/build/SonarOpenCommunity/sonar-cxx/integration-tests/testdata behave --no-capture --tags=$SONARAPI
after_failure:
- cat $SONARHOME/logs/sonar.log
- find . -name "*.log" | xargs cat