divide and conquer

This commit is contained in:
Eric Vergnaud 2016-11-28 00:56:14 +08:00
parent c695ed25e9
commit 4f48d533fa
17 changed files with 101 additions and 23 deletions

View File

@ -1,24 +1,52 @@
sudo: true sudo: true
language: java
env:
- TARGET=java
- TARGET=csharp
- TARGET=python2
- TARGET=python3
- TARGET=javascript
- TARGET=cpp
- TARGET=go
- TARGET=swift
matrix: matrix:
include: include:
- os: linux - os: linux
env: CXX=g++-5 env: CXX=g++-5
compiler: clang compiler: clang
language: java
jdk: oraclejdk7 jdk: oraclejdk7
- os: osx - os: osx
compiler: clang compiler: clang
language: java
osx_image: xcode8.1 osx_image: xcode8.1
exclude:
- os: linux
env: TARGET=swift
- os: osx
env: TARGET=java
- os: osx
env: TARGET=csharp
- os: osx
env: TARGET=python2
- os: osx
env: TARGET=python3
- os: osx
env: TARGET=javascript
- os: osx
env: TARGET=cpp
- os: osx
env: TARGET=go
before_install:
- ./.travis/before-install-$TRAVIS_OS_NAME-$TARGET.sh
- fi
script: script:
- if [[ $TRAVIS_OS_NAME == osx ]]; then cd runtime-testsuite; ../.travis/run-tests-macos.sh; fi - cd runtime-testsuite
- if [[ $TRAVIS_OS_NAME == linux ]]; then cd runtime-testsuite; ../.travis/run-tests-linux.sh; fi - ../.travis/run-tests-$TARGET.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
addons: addons:
apt: apt:

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,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
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

View File

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

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

@ -0,0 +1,3 @@
#!/bin/bash
mvn -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 -Dparallel=methods -DthreadCount=4 -Dtest=csharp.* test

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

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

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

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

View File

@ -0,0 +1,3 @@
#!/bin/bash
mvn -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 -Dparallel=methods -DthreadCount=4 -Dtest=python2.* test

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

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