diff options
author | Niels de Vos <ndevos@redhat.com> | 2013-07-12 15:00:07 +0200 |
---|---|---|
committer | Anand Avati <avati@redhat.com> | 2013-07-15 10:44:27 -0700 |
commit | c50aa14008f9612d273acb81470f544cad6cff1a (patch) | |
tree | 6e1c8801c3480ae7af54ddd8df90499510b2d42f | |
parent | 3f6a5702642837411477f241c9756c1872d46b1f (diff) |
tests: call 'cleanup' at the end of each test
Some tests do not cleanup after themselves. That is bad behaviour and
makes it difficult to run single tests and verify the state of the
system afterwards.
Change-Id: I4ac5401d790d6bc81e6975fd1384874b21d6cf8a
BUG: 983975
Signed-off-by: Niels de Vos <ndevos@redhat.com>
Reviewed-on: http://review.gluster.org/5328
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
Reviewed-by: Anand Avati <avati@redhat.com>
-rw-r--r-- | tests/basic/nufa.t | 2 | ||||
-rw-r--r-- | tests/bugs/bug-856455.t | 2 | ||||
-rw-r--r-- | tests/bugs/bug-860663.t | 2 | ||||
-rw-r--r-- | tests/bugs/bug-862967.t | 2 | ||||
-rw-r--r-- | tests/bugs/bug-878004.t | 1 | ||||
-rwxr-xr-x | tests/bugs/bug-884455.t | 2 | ||||
-rwxr-xr-x | tests/bugs/bug-893378.t | 2 | ||||
-rwxr-xr-x | tests/bugs/bug-902610.t | 1 |
8 files changed, 14 insertions, 0 deletions
diff --git a/tests/basic/nufa.t b/tests/basic/nufa.t index 05aaceec6b2..0d4c229a0fa 100644 --- a/tests/basic/nufa.t +++ b/tests/basic/nufa.t @@ -28,3 +28,5 @@ sleep 5; ## Mount NFS TEST mount -t nfs -o nolock,soft,intr $H0:/$V0 $N0; + +cleanup; diff --git a/tests/bugs/bug-856455.t b/tests/bugs/bug-856455.t index 1b2438b0481..becb202225f 100644 --- a/tests/bugs/bug-856455.t +++ b/tests/bugs/bug-856455.t @@ -38,3 +38,5 @@ EXPECT $BRICK_COUNT query_pathinfo $M0/f00d; kill -9 `cat /var/lib/glusterd/vols/$V0/run/$H0-d-backends-${V0}1.pid`; EXPECT `expr $BRICK_COUNT - 1` query_pathinfo $M0/f00d; + +cleanup; diff --git a/tests/bugs/bug-860663.t b/tests/bugs/bug-860663.t index 28d1f8fcddc..05dea5fbc05 100644 --- a/tests/bugs/bug-860663.t +++ b/tests/bugs/bug-860663.t @@ -47,3 +47,5 @@ sleep 5; NEW_FILE_COUNT=`ls -l $M0 | wc -l`; EXPECT "0" file_count $ORIG_FILE_COUNT $NEW_FILE_COUNT + +cleanup; diff --git a/tests/bugs/bug-862967.t b/tests/bugs/bug-862967.t index 73f5826fa47..00fa884408a 100644 --- a/tests/bugs/bug-862967.t +++ b/tests/bugs/bug-862967.t @@ -55,3 +55,5 @@ BACKEND_GID=`stat --printf=%g $B0/${V0}1/dir`; EXPECT "0" uid_gid_compare $NEW_UID $NEW_GID $BACKEND_UID $BACKEND_GID + +cleanup; diff --git a/tests/bugs/bug-878004.t b/tests/bugs/bug-878004.t index 5397be2a663..5bee4c62fc3 100644 --- a/tests/bugs/bug-878004.t +++ b/tests/bugs/bug-878004.t @@ -25,4 +25,5 @@ EXPECT '2' brick_count $V0 TEST $CLI volume remove-brick $V0 $H0:$B0/${V0}3; EXPECT '1' brick_count $V0 +cleanup; diff --git a/tests/bugs/bug-884455.t b/tests/bugs/bug-884455.t index 46e55dad61e..3b3a2241e14 100755 --- a/tests/bugs/bug-884455.t +++ b/tests/bugs/bug-884455.t @@ -80,3 +80,5 @@ EXPECT "0" get_layout $B0/${V0}0/dir7 $B0/${V0}1/dir7 $B0/${V0}2/dir7 EXPECT "0" get_layout $B0/${V0}0/dir8 $B0/${V0}1/dir8 $B0/${V0}2/dir8 EXPECT "0" get_layout $B0/${V0}0/dir9 $B0/${V0}1/dir9 $B0/${V0}2/dir9 EXPECT "0" get_layout $B0/${V0}0/dir10 $B0/${V0}1/dir10 $B0/${V0}2/dir10 + +cleanup; diff --git a/tests/bugs/bug-893378.t b/tests/bugs/bug-893378.t index 470589f5375..fd8b9a7ceba 100755 --- a/tests/bugs/bug-893378.t +++ b/tests/bugs/bug-893378.t @@ -69,3 +69,5 @@ ls -l $M0/2 2>/dev/null dd if=/dev/zero of=$M0/2 bs=1 count=1 conv=excl 2>/dev/null EXPECT "1" echo $? + +cleanup; diff --git a/tests/bugs/bug-902610.t b/tests/bugs/bug-902610.t index f5eb6be0287..00ba03adfce 100755 --- a/tests/bugs/bug-902610.t +++ b/tests/bugs/bug-902610.t @@ -56,3 +56,4 @@ mkdir $M0/dir1 2>/dev/null get_layout $B0/${V0}0/dir1 $B0/${V0}1/dir1 EXPECT "0" echo $? +cleanup; |