]> git.ipfire.org Git - thirdparty/lldpd.git/commitdiff
travis: try to run integration tests feature/pytest 168/head
authorVincent Bernat <vincent@bernat.im>
Sun, 13 Mar 2016 19:51:03 +0000 (20:51 +0100)
committerVincent Bernat <vincent@bernat.im>
Sun, 13 Mar 2016 23:28:58 +0000 (00:28 +0100)
.travis.yml
.travis/install.sh
.travis/run.sh
tests/integration/requirements.txt

index b14ec1f7c1dc2654a512be0473f8116a4370505d..b3a161d7770a2ee977f18c982f4f61d731642dfc 100644 (file)
@@ -1,5 +1,6 @@
 language: c
 os: linux
+dist: trusty
 compiler: gcc
 sudo: require
 install:
index d758d5abd591226fa83aa156ef85061162a40382..ea6992329c8d3d9879f74e47b9571c65543c2605 100755 (executable)
@@ -30,9 +30,8 @@ case "$(uname -s)" in
             libsnmp-dev libxml2-dev libjansson-dev \
             libevent-dev libreadline-dev libbsd-dev \
             check
-        [ x"$RUN_INTEGRATION" != x"1" ] || \
-            sudo apt-get -qqy install \
-                 vde2 iproute qemu \
-                 bridge-utils busybox
+        python3 -V && \
+            python3 -m pip -V && \
+            sudo -H $(which python3) -m pip install -r tests/integration/requirements.txt
         ;;
 esac
index 70c10f9f3beea27d6e7276b471c74d33b756ae06..1678bb84ea2590a66bec1ab8e5f8e6d9b997dfb8 100755 (executable)
@@ -15,7 +15,7 @@ case "${RUN_COVERITY}","${TRAVIS_BRANCH}" in
 esac
 
 ./autogen.sh
-./configure $LLDPD_CONFIG_ARGS --enable-pie CFLAGS="-O0 -g"
+./configure $LLDPD_CONFIG_ARGS --enable-pie --localstatedir=/var --sysconfdir=/etc --prefix=/usr CFLAGS="-O0 -g"
 
 if [ x"${RUN_COVERITY}" = x"1" ]; then
     # Coverity build
@@ -27,15 +27,12 @@ if [ x"${RUN_COVERITY}" = x"1" ]; then
 else
     # Regular build
     make all check CFLAGS=-Werror
-    if [ x"$RUN_INTEGRATION" = x"1" ]; then
-        cd tests
-        sudo setfacl -m u:$(id -un):r /boot/vmlinuz-*
-        make integration-tests
-        sh integration-tests
-    else
-        make distcheck
-        if [ x"$TRAVIS_OS_NAME" = x"osx" ]; then
-            make -C osx pkg
-        fi
+    make distcheck
+    if [ x"$TRAVIS_OS_NAME" = x"osx" ]; then
+        make -C osx pkg
+    fi
+    if [ x"$TRAVIS_OS_NAME" = x"linux" ]; then
+        cd tests/integration
+        sudo $(which python3) -m pytest -n 5 -vvv -x --boxed
     fi
 fi
index 85d027814d036b78a51711c311e07376c2154400..9528dae7cf3b6668fb1ea1e3873cff74699599cb 100644 (file)
@@ -1,6 +1,5 @@
 apipkg==1.4
 execnet==1.4.1
-pkg-resources==0.0.0
 py==1.4.31
 pyroute2==0.3.16
 pytest==2.9.0