From 8386c1a210b51f9c3f9a3be11ed062f33d46dd9c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Helleu?= Date: Tue, 22 Jul 2014 21:05:53 +0200 Subject: [PATCH] tests: run tests after build on Travis CI --- .travis.yml | 3 ++- scripts/build.sh | 6 ++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index f38caa428..0a46dd091 100644 --- a/.travis.yml +++ b/.travis.yml @@ -10,8 +10,9 @@ env: before_script: - echo 'APT::Install-Recommends "false";' | sudo tee -a /etc/apt/apt.conf + - sudo add-apt-repository ppa:bcandrea/backports - sudo apt-get update -qq - - sudo apt-get -y install devscripts equivs python-pip libenchant-dev autopoint + - sudo apt-get -y install devscripts equivs python-pip libenchant-dev autopoint libcpputest-dev - sudo mk-build-deps -i debian/control - sudo pip install msgcheck pylint diff --git a/scripts/build.sh b/scripts/build.sh index 2f00c3e2a..1a60f3452 100755 --- a/scripts/build.sh +++ b/scripts/build.sh @@ -52,15 +52,17 @@ run "cd $BUILDDIR" if [ "$BUILDTOOL" = "cmake" ]; then # build with CMake - run "cmake .. -DENABLE_MAN=ON -DENABLE_DOC=ON" + run "cmake .. -DENABLE_MAN=ON -DENABLE_DOC=ON -DENABLE_TESTS=ON" run "make VERBOSE=1" run "sudo make install" + run "ctest -V" fi if [ "$BUILDTOOL" = "autotools" ]; then # build with autotools run "../autogen.sh" - run "../configure --enable-man --enable-doc" + run "../configure --enable-man --enable-doc --enable-tests" run "make" run "sudo make install" + run "./tests/tests -v" fi