summaryrefslogtreecommitdiffstats
path: root/tests/basic/ec
diff options
context:
space:
mode:
authorEmmanuel Dreyfus <manu@netbsd.org>2014-08-08 05:39:38 +0200
committerHarshavardhana <harsha@harshavardhana.net>2014-08-20 13:46:44 -0700
commit33be39b42f3b9b0505f83a509ff87d416e106158 (patch)
tree94facdd61792f0677898927cd0bcbfe30f0c8084 /tests/basic/ec
parenta521fc1d22db5477552c0fabc1f918b43caa50c3 (diff)
Regression test portability: mktemp
Linux mktemp accepts to run without a template, NetBSD mandates it. Since the template option has the same syntax, add it everywhere. While there, also do this in scripts outside of regression testing. BUG: 764655 Change-Id: I3ec140afbc9009257c81a56d77afcc21fef74cc4 Signed-off-by: Emmanuel Dreyfus <manu@netbsd.org> Reviewed-on: http://review.gluster.org/8432 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Harshavardhana <harsha@harshavardhana.net> Tested-by: Harshavardhana <harsha@harshavardhana.net>
Diffstat (limited to 'tests/basic/ec')
-rw-r--r--tests/basic/ec/ec-common2
-rw-r--r--tests/basic/ec/ec.t2
-rw-r--r--tests/basic/ec/self-heal.t2
3 files changed, 3 insertions, 3 deletions
diff --git a/tests/basic/ec/ec-common b/tests/basic/ec/ec-common
index b52fecbd9a9..89b972b147a 100644
--- a/tests/basic/ec/ec-common
+++ b/tests/basic/ec/ec-common
@@ -14,7 +14,7 @@ function fragment_size
cleanup
-tmp=`mktemp -d`
+tmp=`mktemp -d -t ${0##*/}.XXXXXX`
if [ ! -d $tmp ]; then
exit 1
fi
diff --git a/tests/basic/ec/ec.t b/tests/basic/ec/ec.t
index e81de0d97bd..d069fac4fec 100644
--- a/tests/basic/ec/ec.t
+++ b/tests/basic/ec/ec.t
@@ -143,7 +143,7 @@ EXPECT 'Started' volinfo_field $V0 'Status'
TEST glusterfs --entry-timeout=0 --attribute-timeout=0 -s $H0 --volfile-id $V0 $M0
# Create local files for comparisons etc.
-tmpdir=$(mktemp -d)
+tmpdir=$(mktemp -d -t ${0##*/}.XXXXXX)
trap "rm -rf $tmpdir" EXIT
TEST create_file $tmpdir/create-write 10
TEST create_file $tmpdir/truncate 10
diff --git a/tests/basic/ec/self-heal.t b/tests/basic/ec/self-heal.t
index 99cfd9420aa..f3f2cc23d3f 100644
--- a/tests/basic/ec/self-heal.t
+++ b/tests/basic/ec/self-heal.t
@@ -7,7 +7,7 @@
cleanup
-tmp=`mktemp -d`
+tmp=`mktemp -d -t ${0##*/}.XXXXXX`
if [ ! -d $tmp ]; then
exit 1
fi