From 43c8a51e863383ee30ce8bc8168fd689766d04c1 Mon Sep 17 00:00:00 2001 From: Nigel Babu Date: Mon, 19 Jun 2017 11:32:32 +0530 Subject: On master, only run tests/basic in regression * Give experimental branch a free pass for Centos Regression * Run shellcheck on scripts to remove problematic warnings Change-Id: I939b4bb09bae4dd65efe1e80a43f69fee4bbf9ac --- build-gluster-org/scripts/netbsd7-regression.sh | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'build-gluster-org/scripts/netbsd7-regression.sh') diff --git a/build-gluster-org/scripts/netbsd7-regression.sh b/build-gluster-org/scripts/netbsd7-regression.sh index 77acab7..83c8d7b 100644 --- a/build-gluster-org/scripts/netbsd7-regression.sh +++ b/build-gluster-org/scripts/netbsd7-regression.sh @@ -1,5 +1,5 @@ #!/bin/bash -MY_ENV=`env | sort` +MY_ENV=$(env | sort) BURL=${BUILD_URL}consoleFull # Display all environment variables in the debugging log @@ -15,7 +15,8 @@ echo # Exit early with success if the change is on release-3.{5,6} # NetBSD regression doesn't run successfully on release-3.{5,6} # FB gets a pass on regressions on their branch. -if [ $GERRIT_BRANCH = "release-3.5" -o $GERRIT_BRANCH = "release-3.6" -o $GERRIT_BRANCH = "release-3.8-fb" ]; then +# Experimental also gets a pass +if [ "$GERRIT_BRANCH" = "release-3.5" ] || [ "$GERRIT_BRANCH" = "release-3.6" ] || [ "$GERRIT_BRANCH" = "release-3.8-fb" ] || [ "$GERRIT_BRANCH" = "experimental" ]; then echo "Skipping regression run for ${GERRIT_BRANCH}" RET=0 VERDICT="Skipped for ${GERRIT_BRANCH}" @@ -35,7 +36,7 @@ su -l root -c "chown -R jenkins /usr/pkg/lib/python2.7/site-packages/gluster" # Clean up the git repo su -l root -c "rm -rf $WORKSPACE/.gitignore $WORKSPACE/*" su -l root -c "chown -R jenkins $WORKSPACE" -cd $WORKSPACE +cd $WORKSPACE || exit 1 git reset --hard HEAD # Clean up other Gluster dirs @@ -49,7 +50,7 @@ su -l root -c "rm -rf /var/log/glusterfs/* /var/log/glusterfs/.cmd_log_history" # Skip tests for certain folders SKIP=true -for file in `git diff-tree --no-commit-id --name-only -r HEAD`; do +for file in $(git diff-tree --no-commit-id --name-only -r HEAD); do if [[ $file != doc/* ]] && [[ $file != build-aux/* ]] && [[ $file != tests/distaf/* ]]; then SKIP=false break @@ -96,11 +97,9 @@ su -l root -c "cd $WORKSPACE && /opt/qa/regression.sh" RET=$? if [ $RET = 0 ]; then V="+1" - R="0" VERDICT="SUCCESS" else V="-1" - R="0" VERDICT="FAILED" fi -- cgit