More folds and reorder some build instructions

This commit is contained in:
Patrick Niklaus 2016-04-25 00:19:48 +02:00
parent 15e3928906
commit cc35d15b2d
No known key found for this signature in database
GPG Key ID: E426891B5F978B1B
2 changed files with 14 additions and 6 deletions

View File

@ -129,28 +129,32 @@ before_script:
- cmake .. -DCMAKE_BUILD_TYPE=${BUILD_TYPE} -DBUILD_SHARED_LIBS=${BUILD_SHARED_LIBS:-OFF} -DCOVERAGE=${COVERAGE:-OFF} -DBUILD_TOOLS=1 -DENABLE_CCACHE=0
script:
- echo "travis_fold:start:MAKE"
- make --jobs=2
- make tests --jobs=2
- make benchmarks
- echo "travis_fold:end:MAKE"
- echo "travis_fold:start:INSTALL"
- sudo make install
- |
if [[ "${TRAVIS_OS_NAME}" == "linux" ]]; then
sudo ldconfig
fi
- echo "travis_fold:end:INSTALL"
- echo "travis_fold:start:BENCHMARK"
- make -C ../test/data benchmark
- echo "travis_fold:end:BENCHMARK"
- echo "travis_fold:start:UNIT_TESTS"
- ./unit_tests/extractor-tests
- ./unit_tests/engine-tests
- ./unit_tests/util-tests
- ./unit_tests/server-tests
- ./unit_tests/library-tests test/data/monaco.osrm
- echo "travis_fold:end:UNIT_TESTS"
- popd
- echo "travis_fold:start:CUCUMBER"
- npm test
- echo "travis_fold:end:CUCUMBER"
- echo "travis_fold:start:BENCHMARK"
- make -C test/data benchmark
- echo "travis_fold:end:BENCHMARK"
- ./build/unit_tests/library-tests test/data/monaco.osrm
- mkdir example/build && pushd example/build
- cmake ..
- make
@ -159,7 +163,10 @@ script:
after_success:
- |
if [ -n "$RUN_CLANG_FORMAT" ]; then
if [ -n "${RUN_CLANG_FORMAT}" ]; then
./scripts/format.sh || true # we don't want to fail just yet
fi
- coveralls --build-root build --exclude unit_tests --exclude third_party --exclude node_modules --gcov-options '\-lp'
- |
if [ -n "${COVERAGE}" ]; then
coveralls --build-root build --exclude unit_tests --exclude third_party --exclude node_modules --gcov-options '\-lp'
fi

View File

@ -140,6 +140,7 @@ if (COVERAGE)
if (NOT CMAKE_BUILD_TYPE MATCHES "Debug")
message(ERROR "COVERAGE=ON only make sense with a Debug build")
endif()
message(INFO "Enabling coverage")
set(MAYBE_COVERAGE_LIBRARIES "gcov")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -ftest-coverage -fprofile-arcs")
endif()