-
Notifications
You must be signed in to change notification settings - Fork 754
/
.travis.yml
130 lines (121 loc) · 4.21 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
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
# Copyright (c) 2017, WSO2 Inc. (http://wso2.com) All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
language: node_js
node_js:
- "8"
sudo: required
git:
quiet: true
services:
- docker
jobs:
include:
- stage: "Build and Check(Windows + Linux)"
name: "Build without tests - Windows"
os: windows
language: node_js
install:
- choco install jdk8 -params 'installdir=c:\\java8'
- export JAVA_HOME="c:\\java8"
- export PATH="$PATH;$JAVA_HOME\\bin"
script:
- while sleep 9m; do echo "=====[ $SECONDS seconds still running ]====="; done &
- ./gradlew.bat build -x test -x javadoc --stacktrace -scan --console=plain --no-daemon
# Killing background sleep loop
- kill %1
name: "Build without tests - Windows"
- script:
- while sleep 9m; do echo "=====[ $SECONDS seconds still running ]====="; done &
- ./gradlew build -x test -x javadoc --stacktrace -scan --console=plain --no-daemon
# Killing background sleep loop
- kill %1
name: "Build without tests - Linux"
os: linux
language: java
jdk: openjdk8
node_js: 8
install: true
before_install:
- nvm install 8
- nvm use 8
- npm install -g npm@'5.6.0'
- stage: "Tests"
name: "Run Build + tests (without integration) - Linux"
script:
- while sleep 9m; do echo "=====[ $SECONDS seconds still running ]====="; done &
- ./gradlew build -x :jballerina-integration-test:test -x :testerina-integration-test:test -x javadoc --stacktrace -scan --console=plain --no-daemon
# Killing background sleep loop
- kill %1
os: linux
language: java
jdk: openjdk8
node_js: 8
before_install:
- nvm install 8
- nvm use 8
- npm install -g npm@'5.6.0'
install:
- |
if [ $TRAVIS_OS_NAME == "linux" ]; then
export DISPLAY=':99.0'
/usr/bin/Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
fi
- script:
- while sleep 9m; do echo "=====[ $SECONDS seconds still running ]====="; done &
# TODO enable tests for all projects
- ./gradlew.bat build -Dorg.gradle.parallel=false -x :ballerina-packerina:test -x :ballerina-lang:test -x :jballerina-unit-test:test -x :jballerina-integration-test:test -x javadoc --stacktrace -scan --console=plain --no-daemon
# Killing background sleep loop
- kill %1
name: "Tests - windows"
os: windows
language: node_js
node_js: 8
install:
- choco install jdk8 -params 'installdir=c:\\java8'
- export JAVA_HOME="c:\\java8"
- export PATH="$PATH;$JAVA_HOME\\bin"
- script:
- while sleep 9m; do echo "=====[ $SECONDS seconds still running ]====="; done &
- ./gradlew :jballerina-integration-test:test :testerina-integration-test:test -x javadoc --stacktrace -scan --console=plain --no-daemon
# Killing background sleep loop
- kill %1
os: linux
install: true
language: java
jdk: openjdk8
node_js: 8
before_install:
- nvm install 8
- nvm use 8
- npm install -g npm@'5.6.0'
name: "Integration tests - Linux"
after_success:
- bash <(curl -s https://codecov.io/bash)
before_cache:
- rm -f $HOME/.gradle/caches/modules-2/modules-2.lock
- rm -fr $HOME/.gradle/caches/*/plugin-resolution/
- rm -fr $HOME/.gradle/caches/*/scripts/
cache:
directories:
- $HOME/.gradle/caches/
- $HOME/.gradle/wrapper/
- $HOME/.m2
branches:
only:
- packerina-dev
- next-release
- release-stage
- new-transaction-impl
- stage
- /^ballerina-\d*[.]\d*[.]x$/