summaryrefslogtreecommitdiffstats
path: root/tests/basic
diff options
context:
space:
mode:
authorCsaba Henk <csaba@redhat.com>2017-08-01 01:38:00 +0200
committerJeff Darcy <jeff@pl.atyp.us>2017-08-02 20:56:17 +0000
commitc7e5741f938e24b85976bf78ea7d84984a4e1e61 (patch)
tree9c2642ec2e74f75c4a858bd006ca522a12c21f1b /tests/basic
parentf17eefb6d9a91cfccc3bef3aa3ba08a9128b046e (diff)
tests: don't use hard coded value for glusterd workdir
A number of test referred to /var/lib/glusterd, they were adjusted to use "$GLUSTERD_WORKDIR". (This has significance for proper test runs on non-Linux platforms -- see the following #define in glusterfs.h: #ifdef GF_LINUX_HOST_OS #define GLUSTERD_DEFAULT_WORKDIR DATADIR "/lib/glusterd" #else #define GLUSTERD_DEFAULT_WORKDIR DATADIR "/db/glusterd" #endif Ie. the glusterd workdir will typically be /var/db/glusterd instead of /var/lib/glusterd on non-Linux platforms.) BUG: 1476957 Change-Id: I69ce3e1bb7a0c14ea85b60adbf8205f9aca46cd5 Signed-off-by: Csaba Henk <csaba@redhat.com> Reviewed-on: https://review.gluster.org/17937 Smoke: Gluster Build System <jenkins@build.gluster.org> Reviewed-by: Amar Tumballi <amarts@redhat.com> Tested-by: Amar Tumballi <amarts@redhat.com> CentOS-regression: Gluster Build System <jenkins@build.gluster.org> Reviewed-by: Jeff Darcy <jeff@pl.atyp.us>
Diffstat (limited to 'tests/basic')
-rwxr-xr-xtests/basic/mount-nfs-auth.t2
-rw-r--r--tests/basic/peer-parsing.t2
2 files changed, 2 insertions, 2 deletions
diff --git a/tests/basic/mount-nfs-auth.t b/tests/basic/mount-nfs-auth.t
index cd0189788ba..082dbbbdcf1 100755
--- a/tests/basic/mount-nfs-auth.t
+++ b/tests/basic/mount-nfs-auth.t
@@ -41,7 +41,7 @@ function build_dirs () {
}
function export_allow_this_host_ipv6 () {
- printf "$EXPORT_ALLOW6\n" > /var/lib/glusterd/nfs/exports
+ printf "$EXPORT_ALLOW6\n" > "$GLUSTERD_WORKDIR"/nfs/exports
}
function export_allow_this_host () {
diff --git a/tests/basic/peer-parsing.t b/tests/basic/peer-parsing.t
index 210ec8ccd90..813b65e2ae1 100644
--- a/tests/basic/peer-parsing.t
+++ b/tests/basic/peer-parsing.t
@@ -2,7 +2,7 @@
. $(dirname $0)/../include.rc
-PEER_DIR=/var/lib/glusterd/peers
+PEER_DIR="$GLUSTERD_WORKDIR"/peers
TEST mkdir -p $PEER_DIR
declare -i HOST_NUM=100