Merge pull request #1413 from ericvergnaud/split-travis-build

divide and conquer Travis CI
This commit is contained in:
Terence Parr 2016-11-27 13:31:18 -08:00 committed by GitHub
commit 508a23c8f5
19 changed files with 143 additions and 41 deletions

View File

@ -1,25 +1,15 @@
sudo: true
language: java
matrix:
include:
- os: linux
env: CXX=g++-5
compiler: clang
language: java
jdk: oraclejdk7
- os: osx
compiler: clang
language: java
osx_image: xcode8.1
script:
- if [[ $TRAVIS_OS_NAME == osx ]]; then cd runtime-testsuite; ../.travis/run-tests-macos.sh; fi
- if [[ $TRAVIS_OS_NAME == linux ]]; then cd runtime-testsuite; ../.travis/run-tests-linux.sh; fi
before_install:
- if [[ $TRAVIS_OS_NAME == osx ]]; then ./.travis/before-install-macos.sh; fi
- if [[ $TRAVIS_OS_NAME == linux ]]; then ./.travis/before-install-linux.sh; fi
env:
- TARGET=cpp
- CXX=g++-5
addons:
apt:
sources:
@ -29,3 +19,49 @@ addons:
- g++-5
- uuid-dev
- clang-3.7
- os: osx
compiler: clang
osx_image: xcode8.1
env: TARGET=cpp
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- llvm-toolchain-precise-3.7
packages:
- g++-5
- uuid-dev
- clang-3.7
- os: osx
compiler: clang
osx_image: xcode8.1
env: TARGET=swift
- os: linux
jdk: oraclejdk7
env: TARGET=java
- os: linux
jdk: oraclejdk8
env: TARGET=java
- os: linux
jdk: oraclejdk7
env: TARGET=csharp
- os: linux
jdk: oraclejdk7
env: TARGET=python2
- os: linux
jdk: oraclejdk7
env: TARGET=python3
- os: linux
jdk: oraclejdk7
env: TARGET=javascript
- os: linux
jdk: oraclejdk7
env: TARGET=go
before_install:
- ./.travis/before-install-$TRAVIS_OS_NAME-$TARGET.sh
script:
- cd runtime-testsuite
- ../.travis/run-tests-$TARGET.sh

View File

@ -0,0 +1,8 @@
#!/bin/bash
set -euo pipefail
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
sudo add-apt-repository ppa:fkrull/deadsnakes -y
sudo add-apt-repository ppa:rwky/nodejs -y
sudo apt-get update -qq

View File

@ -6,12 +6,5 @@ sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328
sudo add-apt-repository ppa:fkrull/deadsnakes -y
sudo add-apt-repository ppa:rwky/nodejs -y
sudo apt-get update -qq
sudo apt-get install -qq python3.5
sudo apt-get install -qq nodejs
echo "deb http://download.mono-project.com/repo/debian wheezy/snapshots/3.12.1 main" | sudo tee /etc/apt/sources.list.d/mono-xamarin.list
sudo apt-get install -qq mono-complete
eval "$(sudo gimme 1.7.3)"
( go version ; go env ) || true
python --version
python3 --version

View File

@ -0,0 +1,10 @@
#!/bin/bash
set -euo pipefail
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
sudo add-apt-repository ppa:fkrull/deadsnakes -y
sudo add-apt-repository ppa:rwky/nodejs -y
sudo apt-get update -qq
eval "$(sudo gimme 1.7.3)"
( go version ; go env ) || true

View File

@ -0,0 +1,8 @@
#!/bin/bash
set -euo pipefail
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
sudo add-apt-repository ppa:fkrull/deadsnakes -y
sudo add-apt-repository ppa:rwky/nodejs -y
sudo apt-get update -qq

View File

@ -0,0 +1,9 @@
#!/bin/bash
set -euo pipefail
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
sudo add-apt-repository ppa:fkrull/deadsnakes -y
sudo add-apt-repository ppa:rwky/nodejs -y
sudo apt-get update -qq
sudo apt-get install -qq nodejs

View File

@ -0,0 +1,9 @@
#!/bin/bash
set -euo pipefail
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
sudo add-apt-repository ppa:fkrull/deadsnakes -y
sudo add-apt-repository ppa:rwky/nodejs -y
sudo apt-get update -qq
python --version

View File

@ -0,0 +1,10 @@
#!/bin/bash
set -euo pipefail
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
sudo add-apt-repository ppa:fkrull/deadsnakes -y
sudo add-apt-repository ppa:rwky/nodejs -y
sudo apt-get update -qq
sudo apt-get install -qq python3.5
python3 --version

View File

@ -5,13 +5,9 @@ set -euo pipefail
thisdir=$(dirname "$0")
brew update
brew install mono python3 cmake
brew install cmake
# Work around apparent rvm bug that is in Travis's Xcode image.
# https://github.com/direnv/direnv/issues/210
# https://github.com/travis-ci/travis-ci/issues/6307
shell_session_update() { :; }
( go version ; go env ) || true
python --version
python3 --version

View File

@ -0,0 +1,12 @@
#!/bin/bash
set -euo pipefail
thisdir=$(dirname "$0")
brew update
# Work around apparent rvm bug that is in Travis's Xcode image.
# https://github.com/direnv/direnv/issues/210
# https://github.com/travis-ci/travis-ci/issues/6307
shell_session_update() { :; }

3
.travis/run-tests-cpp.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/bash
mvn -q -Dtest=cpp.* test # timeout due to no output for 10 min on travis if in parallel

3
.travis/run-tests-csharp.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/bash
mvn -q -Dparallel=methods -DthreadCount=4 -Dtest=csharp.* test

3
.travis/run-tests-go.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/bash
mvn -q -Dparallel=methods -DthreadCount=4 -Dtest=go.* test

3
.travis/run-tests-java.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/bash
mvn -q -Dparallel=methods -DthreadCount=4 -Dtest=java.* test

View File

@ -0,0 +1,3 @@
#!/bin/bash
mvn -q -Dparallel=methods -DthreadCount=4 -Dtest=node.* test

View File

@ -1,10 +0,0 @@
#!/bin/bash
mvn -Dparallel=methods -DthreadCount=4 -Dtest=java.* test
mvn -Dparallel=methods -DthreadCount=4 -Dtest=csharp.* test
mvn -Dparallel=methods -DthreadCount=4 -Dtest=python2.* test
mvn -Dparallel=methods -DthreadCount=4 -Dtest=python3.* test
mvn -Dparallel=methods -DthreadCount=4 -Dtest=node.* test
mvn -Dparallel=methods -DthreadCount=4 -Dtest=go.* test
mvn -Dtest=cpp.* test # timeout due to no output for 10 min on travis if in parallel
#mvn -Dparallel=methods -DthreadCount=4 -Dtest=swift.* test

3
.travis/run-tests-python2.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/bash
mvn -q -Dparallel=methods -DthreadCount=4 -Dtest=python2.* test

3
.travis/run-tests-python3.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/bash
mvn -q -Dparallel=methods -DthreadCount=4 -Dtest=python3.* test

View File

@ -1,4 +1,4 @@
#!/bin/bash
# only test swift as we develop on os x so likely well tested and its dog slow on travis
mvn -Dtest=swift.* test
mvn -q -Dtest=swift.* test