cut down on travis testing a bit to make it quicker (#1660)
cut down on travis testing a bit to make it quicker
This commit is contained in:
parent
a9d6d54111
commit
cce5714ee1
42
.travis.yml
42
.travis.yml
|
@ -3,19 +3,19 @@ language: cpp
|
|||
matrix:
|
||||
fast_finish: true
|
||||
include:
|
||||
- env: variant=test_barebones toolset=gcc lint=1
|
||||
- env: variant=test_debug lint=1 tests=1 toolset=gcc-sanitizer
|
||||
- env: variant=test_debug sim=1 ssl=openssl crypto=libcrypto toolset=gcc-sanitizer
|
||||
- env: variant=test_release coverage=1 toolset=gcc-coverage
|
||||
- env: variant=test_release coverage=1 tests=1 toolset=gcc-coverage python=1
|
||||
- env: autotools=1 toolset=gcc
|
||||
- os: osx
|
||||
osx_image: xcode6.4
|
||||
env: variant=test_release docs=1 toolset=darwin
|
||||
env: variant=test_release docs=1 tests=1 toolset=darwin
|
||||
- os: osx
|
||||
osx_image: xcode6.4
|
||||
env: variant=test_debug ssl=openssl crypto=libcrypto toolset=darwin
|
||||
env: variant=test_debug ssl=openssl tests=1 crypto=libcrypto toolset=darwin
|
||||
- os: osx
|
||||
osx_image: xcode6.4
|
||||
env: variant=test_barebones toolset=darwin
|
||||
env: variant=test_barebones tools=1 examples=1 toolset=darwin python=1
|
||||
- dist: trusty
|
||||
env: arch=arm toolset=gcc-arm
|
||||
|
||||
|
@ -51,7 +51,10 @@ before_install:
|
|||
- git submodule update --init --recursive
|
||||
- 'if [[ $ssl == "" ]]; then export ssl=off; fi'
|
||||
- 'if [[ $crypto == "" ]]; then export crypto=built-in; fi'
|
||||
- 'if [[ $TRAVIS_OS_NAME == "osx" && "$variant" != "" ]]; then brew update > /dev/null && brew install --quiet ccache boost-build boost-python; fi'
|
||||
- 'if [[ $TRAVIS_OS_NAME == "osx" && ( "$tests" == "1" || "$sim" == 1 || "$examples" == "1" || "$tools" == "1" || "$python" == "1" ) ]]; then
|
||||
brew update > /dev/null && brew install --quiet ccache boost-build;
|
||||
fi'
|
||||
- 'if [[ $TRAVIS_OS_NAME == "osx" && "$python" == "1" ]]; then brew update > /dev/null && brew install --quiet boost-python; fi'
|
||||
- 'if [ "$docs" = "1" ]; then
|
||||
brew install --quiet docutils;
|
||||
mkdir -p /Users/travis/Library/Python/2.7/lib/python/site-packages;
|
||||
|
@ -65,7 +68,6 @@ before_install:
|
|||
- if [ "$coverage" == "1" ]; then
|
||||
pip install --user codecov;
|
||||
fi
|
||||
- 'if [[ $toolset == "gcc-sanitizer" ]]; then export test_args=testing.arg="--no-stderr-redirect"; fi'
|
||||
- 'echo "toolset: " ${toolset}'
|
||||
- 'echo "variant: " ${variant}'
|
||||
# disable leak checking for now. it reports some suspicious reports against some
|
||||
|
@ -101,10 +103,9 @@ install:
|
|||
- if [ "$docs" == "1" ]; then rst2html.py --version; fi
|
||||
- 'if [ "$lint" == "1" ]; then curl "https://raw.githubusercontent.com/google/styleguide/71ec7f1e524969c19ce33cfc72e8e023f2b98ee2/cpplint/cpplint.py" >~/cpplint.py; fi'
|
||||
|
||||
# osx builds need to disable the deprecated warning because of the openssl
|
||||
# shipping with the system having marked all functions as deprecated. Since
|
||||
# we're building with -Werror, we can't have those warnings
|
||||
- 'if [[ "$variant" != "" ]]; then ccache -V && ccache --show-stats && ccache --zero-stats; fi'
|
||||
- ccache -V
|
||||
- ccache --show-stats
|
||||
- ccache --zero-stats
|
||||
|
||||
- 'if [[ "$arch" == "arm" ]]; then
|
||||
cd test;
|
||||
|
@ -135,25 +136,24 @@ script:
|
|||
python ~/cpplint.py --extensions=cpp --headers=hpp --filter=-,+runtime/explicit,+whitespace/end_of_line --linelength=90 test/*.{cpp,hpp} src/*.cpp include/libtorrent/*.hpp include/libtorrent/kademlia/*.hpp src/kademlia/*.cpp include/libtorrent/aux_/*.hpp include/libtorrent/extensions/*.hpp simulation/*.{cpp,hpp} tools/*.{cpp,hpp} examples/*.{cpp,hpp};
|
||||
fi'
|
||||
|
||||
# if variant is not set, we do not want to build anything
|
||||
# if we are building with code coverage, report it as soon as possible
|
||||
# libtorrent is the name of the test suite target
|
||||
- cd test
|
||||
- 'if [ "$variant" != "" ]; then
|
||||
travis_retry bjam -j3 warnings-as-errors=on ssl=$ssl crypto=$crypto debug-iterators=on picker-debugging=on invariant-checks=full $toolset variant=$variant $test_args libtorrent test_natpmp enum_if -l300 &&
|
||||
- 'if [ "$tests" == "1" ]; then
|
||||
travis_retry bjam -j3 warnings-as-errors=on ssl=$ssl crypto=$crypto debug-iterators=on picker-debugging=on invariant-checks=full $toolset variant=$variant libtorrent test_natpmp enum_if -l300 &&
|
||||
if [ "$coverage" == "1" ]; then
|
||||
codecov --root .. --gcov-exec gcov-5;
|
||||
fi;
|
||||
fi'
|
||||
|
||||
- cd ../examples
|
||||
- 'if [ "$variant" != "" ]; then
|
||||
- 'if [ "$examples" == "1" ]; then
|
||||
bjam -j3 warnings-as-errors=on ssl=$ssl crypto=$crypto debug-iterators=on picker-debugging=on invariant-checks=full $toolset variant=$variant link=shared;
|
||||
fi'
|
||||
- cd ..
|
||||
|
||||
- cd tools
|
||||
- 'if [ "$variant" != "" ]; then
|
||||
- 'if [ "$tools" == "1" ]; then
|
||||
bjam -j3 warnings-as-errors=on ssl=$ssl crypto=$crypto debug-iterators=on picker-debugging=on invariant-checks=full $toolset variant=$variant link=shared;
|
||||
fi'
|
||||
- cd ..
|
||||
|
@ -162,13 +162,13 @@ script:
|
|||
# we have to do this because on linux the name of the python module is the same
|
||||
# as the main library, so we cannot stage them to the same directory
|
||||
# here we specify the temporary lib dir as a path to look for the main library
|
||||
- 'if [ "$variant" != "" ]; then
|
||||
- 'if [ "$python" == "1" ]; then
|
||||
bjam -j3 warnings-as-errors=on ssl=$ssl crypto=$crypto debug-iterators=on picker-debugging=on invariant-checks=full $toolset variant=$variant link=shared install location=./lib;
|
||||
fi'
|
||||
|
||||
# a binary built with sanitizer does not interact well with python
|
||||
- cd bindings/python
|
||||
- 'if [[ "$toolset" != "gcc-sanitizer" && "$variant" != "" ]]; then
|
||||
- 'if [[ "$python" == "1" ]]; then
|
||||
bjam -j3 warnings-as-errors=on ssl=$ssl crypto=$crypto debug-iterators=on picker-debugging=on invariant-checks=full $toolset variant=$variant stage_module libtorrent-link=shared install-type=LIB dll-path=../../lib &&
|
||||
LD_LIBRARY_PATH=../../lib DYLD_LIBRARY_PATH=../../lib python test.py;
|
||||
fi'
|
||||
|
@ -176,8 +176,8 @@ script:
|
|||
|
||||
# simulation
|
||||
- cd simulation
|
||||
- 'if [[ "$variant" != "" && "$sim" == "1" ]]; then
|
||||
bjam -j2 crypto=built-in ssl=off warnings-as-errors=on debug-iterators=on picker-debugging=on invariant-checks=full $test_args $toolset;
|
||||
- 'if [[ "$sim" == "1" ]]; then
|
||||
bjam -j2 crypto=built-in ssl=off warnings-as-errors=on debug-iterators=on picker-debugging=on invariant-checks=full $toolset;
|
||||
fi'
|
||||
- cd ..
|
||||
|
||||
|
@ -191,7 +191,7 @@ script:
|
|||
make -j2 check;
|
||||
fi'
|
||||
|
||||
- 'if [[ "$variant" != "" ]]; then ccache --show-stats; fi'
|
||||
- ccache --show-stats
|
||||
|
||||
- cd test
|
||||
- 'if [[ "$arch" == "arm" ]];
|
||||
|
|
Loading…
Reference in New Issue