summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeff Darcy <jdarcy@redhat.com>2016-02-28 16:34:50 +0530
committerPranith Kumar Karampuri <pkarampu@redhat.com>2016-03-01 18:34:01 -0800
commita25f4e22f8cc68d95468f6873f4f6f0296d4405e (patch)
treec634659a9028445d5498515b352ddeaa1de95ece
parent8210ca1a5c0e78e91c6fab7df7e002e39660b706 (diff)
cli/tests: disable tiering on NetBSD
As proposed in the following email: http://www.gluster.org/pipermail/gluster-devel/2016-February/048464.html Short version: tiering tests on NetBSD are failing often enough to impede other development, and also to cast doubt on whether tiering even works on that platform. The most effective way to satisfy both developers' and users' interests is to disable tiering on NetBSD until such time as someone becomes available to resolve these problems another way. Change-Id: I7375527c339e2650a7e8e900a0d0572013213544 Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.org/13535 Smoke: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Joseph Fernandes CentOS-regression: Gluster Build System <jenkins@build.gluster.com> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
-rw-r--r--cli/src/cli-cmd-volume.c2
-rwxr-xr-xrun-tests.sh25
2 files changed, 23 insertions, 4 deletions
diff --git a/cli/src/cli-cmd-volume.c b/cli/src/cli-cmd-volume.c
index 7122105..74f58ee 100644
--- a/cli/src/cli-cmd-volume.c
+++ b/cli/src/cli-cmd-volume.c
@@ -2519,6 +2519,7 @@ struct cli_cmd volume_cmds[] = {
cli_cmd_volume_rename_cbk,
"rename volume <VOLNAME> to <NEW-VOLNAME>"},*/
+#if !defined(__NetBSD__)
{ "volume tier <VOLNAME> status\n"
"volume tier <VOLNAME> start [force]\n"
"volume tier <VOLNAME> attach [<replica COUNT>] <NEW-BRICK>...\n"
@@ -2538,6 +2539,7 @@ struct cli_cmd volume_cmds[] = {
"NOTE: this is old syntax, will be depreciated in next release. "
"Please use gluster volume tier <vol> detach "
"{start|stop|commit} [force]"},
+#endif
{ "volume add-brick <VOLNAME> [<stripe|replica> <COUNT>] <NEW-BRICK> ... [force]",
cli_cmd_volume_add_brick_cbk,
diff --git a/run-tests.sh b/run-tests.sh
index fe58ed6..258beee 100755
--- a/run-tests.sh
+++ b/run-tests.sh
@@ -8,6 +8,8 @@ retry="no"
tests=""
exit_on_failure="yes"
+OSTYPE=$(uname -s)
+
function check_dependencies()
{
## Check all dependencies are present
@@ -166,7 +168,7 @@ function is_bad_test ()
./tests/basic/tier/bug-1214222-directories_missing_after_attach_tier.t \
./tests/basic/tier/fops-during-migration.t \
./tests/basic/tier/record-metadata-heat.t \
- ./tests/basic/tier/tier-snapshot.t \
+ ./tests/basic/tier/tier-snapshot.t \
./tests/bugs/snapshot/bug-1109889.t \
./tests/bugs/distribute/bug-1066798.t \
./tests/bugs/glusterd/bug-1238706-daemons-stop-on-peer-cleanup.t \
@@ -183,7 +185,16 @@ function is_bad_test ()
; do
[ x"$name" = x"$bt" ] && return 0 # bash: zero means true/success
done
- return 1 # bash: non-zero means false/failure
+ return 1 # bash: non-zero means false/failure
+}
+
+function is_unsupported_test()
+{
+ if [ x"$OSTYPE" != x"NetBSD" ]; then
+ return 1
+ fi
+
+ grep -iqs tier $1
}
function run_tests()
@@ -197,16 +208,22 @@ function run_tests()
for t in $(find ${regression_testsdir}/tests -name '*.t' \
| LC_COLLATE=C sort) ; do
- old_cores=$(ls /core.* 2> /dev/null | wc -l)
+ old_cores=$(ls /core.* 2> /dev/null | wc -l)
if match $t "$@" ; then
echo
echo "=================================================="
- if is_bad_test $t; then
+ if is_bad_test $t; then
echo "Skipping bad test file $t"
echo "=================================================="
echo
continue
fi
+ if is_unsupported_test $t; then
+ echo "Skipping test file $t (feature unsupported on platform)"
+ echo "=================================================="
+ echo
+ continue
+ fi
echo "Running tests in file $t"
starttime="$(date +%s)"
prove -mf --timer $t