From: Peter Stamfest Date: Wed, 12 Mar 2014 16:50:33 +0000 (+0100) Subject: Use automake based checks ("make check") and use the mechanism for travis X-Git-Tag: v1.5.0-rc1~117^2~2^2~19^2~8 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6e3498fb200173c982acb533ef793c31af7d5180;p=thirdparty%2Frrdtool-1.x.git Use automake based checks ("make check") and use the mechanism for travis --- diff --git a/.travis.yml b/.travis.yml index 555ef078..28fad16a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -16,7 +16,7 @@ before_script: script: - ./configure --prefix=/opt/rrdtool-master - make - - cd test && bash alltests ../src/rrdtool + - make check - sudo make install - /opt/rrdtool-master/bin/rrdtool - /opt/rrdtool-master/share/rrdtool/examples/4charts.pl diff --git a/Makefile.am b/Makefile.am index ec47c661..d4efe681 100644 --- a/Makefile.am +++ b/Makefile.am @@ -27,6 +27,8 @@ ACLOCAL_M4= $(top_srcdir)/aclocal.m4 #AUTOHEADER = @AUTOHEADER@ --localdir=$(top_srcdir)/config #AUTOCONF = @AUTOCONF@ --localdir=$(top_srcdir)/config +TESTS = tests/alltests + # $(RSYNC) CHANGES archive/$(PACKAGE)-$(VERSION).tar.gz tobi@ipn.caida.org:/ipn/web/Tools/RRDtool/pub/ if HAVE_SYSTEMD diff --git a/tests/modify1 b/tests/modify1 index 565ac597..68cc39bc 100755 --- a/tests/modify1 +++ b/tests/modify1 @@ -8,14 +8,14 @@ $RRDTOOL create ${BASE}a.rrd --start 1300000000 --step 60 DS:a:GAUGE:120:0:U RR # add 50 values to N=10 for T in $(seq 1300000020 60 1300003020) ; do - rrdtool update ${BASE}a.rrd --template a $T:$N + rrdtool update ${BASE}a.rrd --template a $T:$N || fail "update" let N=$N+10 done $RRDTOOL dump ${BASE}a.rrd | diff - $BASEDIR/modify-test1.create.dump && ok "create" || fail "create" # extend base RRA, refill from coarse RRA -$RRDTOOL modify ${BASE}a.rrd ${BASE}b.rrd RRA#0:+10 +$RRDTOOL modify ${BASE}a.rrd ${BASE}b.rrd RRA#0:+10 || fail "modify" $RRDTOOL dump ${BASE}b.rrd | diff - $BASEDIR/modify-test1.mod1.dump && ok "extend base RRA" || fail "extend base RRA" diff --git a/tests/modify2 b/tests/modify2 index 6a3b64d6..78da8f4c 100755 --- a/tests/modify2 +++ b/tests/modify2 @@ -6,24 +6,24 @@ BASE=$BASEDIR/modify2-test -$RRDTOOL create ${BASE}a.rrd --start 1300000000 --step 60 DS:a:GAUGE:120:0:U RRA:AVERAGE:0.5:1:100 RRA:AVERAGE:0.5:5:2 RRA:MIN:0.5:5:2 RRA:MAX:0.5:5:2 RRA:LAST:0.5:5:2 +$RRDTOOL create ${BASE}a.rrd --start 1300000000 --step 60 DS:a:GAUGE:120:0:U RRA:AVERAGE:0.5:1:100 RRA:AVERAGE:0.5:5:2 RRA:MIN:0.5:5:2 RRA:MAX:0.5:5:2 RRA:LAST:0.5:5:2 || fail create # add 50 values to N=10 for T in $(seq 1300000020 60 1300003020) ; do - $RRDTOOL update ${BASE}a.rrd --template a $T:$N + $RRDTOOL update ${BASE}a.rrd --template a $T:$N || fail update let N=$N+10 done $RRDTOOL dump ${BASE}a.rrd | $DIFF ${BASE}a-create.dump - report create -$RRDTOOL modify ${BASE}a.rrd ${BASE}b.rrd RRA#1:+10 RRA#2:+10 RRA#3:+10 RRA#4:+10 +$RRDTOOL modify ${BASE}a.rrd ${BASE}b.rrd RRA#1:+10 RRA#2:+10 RRA#3:+10 RRA#4:+10 || fail modify $RRDTOOL dump ${BASE}b.rrd | $DIFF ${BASE}b-mod1.dump - report "simultaneously extend aggregate RRAs" -$RRDTOOL modify ${BASE}a.rrd ${BASE}c.rrd RRA:AVERAGE:0.5:2:10 +$RRDTOOL modify ${BASE}a.rrd ${BASE}c.rrd RRA:AVERAGE:0.5:2:10 || fail modify $RRDTOOL dump ${BASE}c.rrd | $DIFF ${BASE}c-mod1.dump - report "add RRA with intermediate pdp_cnt"