From fee6bfc07a68fa25bcc2ca55ef5fb0b80183f9d7 Mon Sep 17 00:00:00 2001 From: Nigel Babu Date: Wed, 21 Jun 2017 13:03:15 +0530 Subject: Switch ignore checks from bash to a script Change-Id: I3eab50eb7399a766128b8d4daa3983dce86fc0d4 --- build-gluster-org/scripts/centos-regression.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/build-gluster-org/scripts/centos-regression.sh b/build-gluster-org/scripts/centos-regression.sh index 952463f..786e07a 100644 --- a/build-gluster-org/scripts/centos-regression.sh +++ b/build-gluster-org/scripts/centos-regression.sh @@ -48,15 +48,17 @@ chmod 755 $JDIRS # Skip tests for certain folders SKIP=true for file in $(git diff-tree --no-commit-id --name-only -r HEAD); do - if [[ $file != doc/* ]] && [[ $file != build-aux/* ]] && [[ $file != tests/distaf/* ]]; then + /opt/qa/is-ignored-file.py file + matched=$? + if [ $matched -eq 1 ]; then SKIP=false break fi done if [[ "$SKIP" == true ]]; then - echo "Patch only modifies doc/*, build-aux/* or tests/distaf/*. Skipping further tests" + echo "Patch only modifies ignored files. Skipping further tests" RET=0 - VERDICT="Skipped tests for doc/*, build-aux/* or tests/distaf/* only change" + VERDICT="Skipped tests for change that only modifies ignored files" V="+1" ssh build@review.gluster.org gerrit review --message "'$BURL : $VERDICT'" --project=glusterfs --label CentOS-regression=$V $GIT_COMMIT exit $RET -- cgit