From 2547fb387e1e5462b3792a77539c9c625db23f0c Mon Sep 17 00:00:00 2001 From: Christoph Galuschka Date: Dec 28 2013 11:14:21 +0000 Subject: Merge commit 'refs/merge-requests/44' of git://gitorious.org/testautomation/t_functional into merge-requests/44 --- diff --git a/tests/p_gzip/10-test-binaries b/tests/p_gzip/10-test-binaries index cd67acb..29435d3 100755 --- a/tests/p_gzip/10-test-binaries +++ b/tests/p_gzip/10-test-binaries @@ -1,5 +1,6 @@ #!/bin/bash # Author: Iain Douglas +# Author: Rene Diepstraten # # Check the binaries from the package exist and run ok @@ -8,11 +9,11 @@ function ExitFail { exit $FAIL } -[ $centos_ver != '6' ] && exit -t_Log "Checking binaries are present and run on C6" +[[ $centos_ver =~ ^6|7$ ]] || exit +t_Log "Checking binaries are present and run on C7" -[ "$(readlink -e /usr/bin/gunzip)" == "/bin/gunzip" ] || ExitFail -[ "$(readlink -e /usr/bin/gzip)" == "/bin/gzip" ] || ExitFail +[ "$(readlink -e /usr/bin/gunzip)" == "/usr/bin/gunzip" ] || ExitFail +[ "$(readlink -e /usr/bin/gzip)" == "/usr/bin/gzip" ] || ExitFail for binary in gunzip gzip zcat gzexe zcmp zdiff zegrep zfgrep zforce zgrep zless zmore znew do diff --git a/tests/p_gzip/20-gzip-test b/tests/p_gzip/20-gzip-test index 055331e..d7bf553 100755 --- a/tests/p_gzip/20-gzip-test +++ b/tests/p_gzip/20-gzip-test @@ -2,6 +2,7 @@ # Author: Athmane Madjoudj # Author: Christoph Galuschka # Author: Iain Douglas +# Author: Rene Diepstraten function ExitFail { t_Log "FAIL" @@ -65,7 +66,7 @@ t_Log "Check -a is ignored as we're on CentOS" if [ $centos_ver == '5' ] then gunzip -a $FILE.gz 2>&1 | head -n 1 | grep -q 'gunzip: option --ascii ignored on this system' || ExitFail -elif [ $centos_ver == '6' ] +elif [[ $centos_ver =~ ^(6|7)$ ]] then gunzip -a $FILE.gz 2>&1 | head -n 1 | grep -q 'gzip: option --ascii ignored on this system' || ExitFail fi