e3c68b
From 427dab431f7e8c4c8a01e9e9ed0892708a3d22d2 Mon Sep 17 00:00:00 2001
e3c68b
From: Atin Mukherjee <amukherj@redhat.com>
e3c68b
Date: Mon, 5 Aug 2019 08:33:29 +0530
e3c68b
Subject: [PATCH 263/265] tests: fix ctime related tests
e3c68b
e3c68b
With ctime being disabled by default, certain tests need to explicitly
e3c68b
turn this option off to sanitize the functionality
e3c68b
e3c68b
Label: DOWNSTREAM ONLY
e3c68b
e3c68b
Change-Id: Id70310b4b09e36bf66756fea447186bb073b5604
e3c68b
BUG: 1704562
e3c68b
Signed-off-by: Atin Mukherjee <amukherj@redhat.com>
e3c68b
Reviewed-on: https://code.engineering.redhat.com/gerrit/177704
e3c68b
Tested-by: RHGS Build Bot <nigelb@redhat.com>
e3c68b
Reviewed-by: Sunil Kumar Heggodu Gopala Acharya <sheggodu@redhat.com>
e3c68b
---
e3c68b
 tests/basic/ctime/ctime-noatime.t | 1 +
e3c68b
 tests/basic/ctime/ctime-readdir.t | 1 +
e3c68b
 tests/bugs/glusterd/bug-1696046.t | 8 +++++---
e3c68b
 3 files changed, 7 insertions(+), 3 deletions(-)
e3c68b
e3c68b
diff --git a/tests/basic/ctime/ctime-noatime.t b/tests/basic/ctime/ctime-noatime.t
e3c68b
index 609ccbd..a6c8d9c 100644
e3c68b
--- a/tests/basic/ctime/ctime-noatime.t
e3c68b
+++ b/tests/basic/ctime/ctime-noatime.t
e3c68b
@@ -20,6 +20,7 @@ function atime_compare {
e3c68b
 TEST glusterd
e3c68b
 TEST pidof glusterd
e3c68b
 TEST $CLI volume create $V0 replica 3 $H0:$B0/${V0}{0,1,2}
e3c68b
+TEST $CLI volume set $V0 ctime on
e3c68b
 TEST $CLI volume set $V0 performance.stat-prefetch off
e3c68b
 TEST $CLI volume set $V0 performance.read-ahead off
e3c68b
 TEST $CLI volume set $V0 performance.quick-read off
e3c68b
diff --git a/tests/basic/ctime/ctime-readdir.t b/tests/basic/ctime/ctime-readdir.t
e3c68b
index 4564fc1..fa069b3 100644
e3c68b
--- a/tests/basic/ctime/ctime-readdir.t
e3c68b
+++ b/tests/basic/ctime/ctime-readdir.t
e3c68b
@@ -9,6 +9,7 @@ TEST glusterd
e3c68b
 
e3c68b
 TEST $CLI volume create $V0 replica 3 ${H0}:$B0/brick{1,2,3};
e3c68b
 TEST $CLI volume set $V0 performance.stat-prefetch on
e3c68b
+TEST $CLI volume set $V0 ctime on
e3c68b
 TEST $CLI volume set $V0 performance.readdir-ahead off
e3c68b
 TEST $CLI volume start $V0;
e3c68b
 
e3c68b
diff --git a/tests/bugs/glusterd/bug-1696046.t b/tests/bugs/glusterd/bug-1696046.t
e3c68b
index e1c1eb2..f7992f5 100644
e3c68b
--- a/tests/bugs/glusterd/bug-1696046.t
e3c68b
+++ b/tests/bugs/glusterd/bug-1696046.t
e3c68b
@@ -22,6 +22,8 @@ TEST pidof glusterd;
e3c68b
 TEST $CLI volume set all cluster.brick-multiplex on
e3c68b
 TEST $CLI volume create $V0 replica 3 $H0:$B0/${V0}{1,2,3};
e3c68b
 TEST $CLI volume create $V1 replica 3 $H0:$B0/${V1}{1,2,3};
e3c68b
+TEST $CLI volume set $V0 ctime on
e3c68b
+TEST $CLI volume set $V1 ctime on
e3c68b
 
e3c68b
 ## Start volume and verify
e3c68b
 TEST $CLI volume start $V0;
e3c68b
@@ -64,9 +66,9 @@ TEST $CLI volume set $V0 diagnostics.brick-log-level DEBUG
e3c68b
 # Do some operation
e3c68b
 touch $M0/file1
e3c68b
 
e3c68b
-# Check debug message debug message should be exist only for V0
e3c68b
-# Server xlator is common in brick_mux so after enabling DEBUG log
e3c68b
-# some debug message should be available for other xlators like posix
e3c68b
+# Check debug message should exist only for V0 server xlator is common in
e3c68b
+# brick_mux so after enabling DEBUG log some debug message should be available
e3c68b
+# for other xlators like posix
e3c68b
 
e3c68b
 brick_log_file=$logdir"/bricks/"`brick-log-file-name`
e3c68b
 nofdlog=$(cat $brick_log_file | grep file1 | grep -v server | wc -l)
e3c68b
-- 
e3c68b
1.8.3.1
e3c68b