[lvm-devel] master - tests: skip valgrind testing when assigned to 0

Zdenek Kabelac zkabelac at fedoraproject.org
Mon Mar 10 11:27:27 UTC 2014


Gitweb:        http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=4eed2c8142dc50e1d359881027aa38a4e4ef2149
Commit:        4eed2c8142dc50e1d359881027aa38a4e4ef2149
Parent:        41e1b12e036ef2079586c4c567eae060c2635062
Author:        Zdenek Kabelac <zkabelac at redhat.com>
AuthorDate:    Sat Mar 8 22:53:23 2014 +0100
Committer:     Zdenek Kabelac <zkabelac at redhat.com>
CommitterDate: Mon Mar 10 12:24:10 2014 +0100

tests: skip valgrind testing when assigned to 0

When LVM_VALGRIND_CLVMD/LVMETAD is set to 0  skip testing.
(Proviosly any value caused to run valgrind testing,
so now '0' skips testing))
---
 test/lib/aux.sh |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/test/lib/aux.sh b/test/lib/aux.sh
index b2d73a6..1426390 100644
--- a/test/lib/aux.sh
+++ b/test/lib/aux.sh
@@ -39,12 +39,12 @@ prepare_clvmd() {
 
 #	lvmconf "activation/monitoring = 1"
 	local run_valgrind=
-	test -z "$LVM_VALGRIND_CLVMD" || run_valgrind="run_valgrind"
+	test "${LVM_VALGRIND_CLVMD:-0}" -eq 0 || run_valgrind="run_valgrind"
 	$run_valgrind lib/clvmd -Isinglenode -d 1 -f &
 	local local_clvmd=$!
 	sleep .3
 	# extra sleep for slow valgrind
-	test -z "$LVM_VALGRIND_CLVMD" || sleep 7
+	test -z "$run_valgrind" || sleep 7
 	# check that it is really running now
 	ps $local_clvmd || die
 	echo $local_clvmd > LOCAL_CLVMD
@@ -77,7 +77,7 @@ prepare_lvmetad() {
 	lvmconf "devices/md_component_detection = 0"
 
 	local run_valgrind=
-	test -z "$LVM_VALGRIND_LVMETAD" || run_valgrind="run_valgrind"
+	test "${LVM_VALGRIND_LVMETAD:-0}" -eq 0 || run_valgrind="run_valgrind"
 
 	echo "preparing lvmetad..."
 	$run_valgrind lvmetad -f "$@" -s "$TESTDIR/lvmetad.socket" -l wire,debug &




More information about the lvm-devel mailing list