Skip to content

Commit

Permalink
Don't run full test when no changes made
Browse files Browse the repository at this point in the history
  • Loading branch information
coke committed Jun 5, 2018
1 parent 239980a commit 9120db3
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions util/update-and-test.sh
Expand Up @@ -6,5 +6,9 @@ OLD=`git rev-parse HEAD`
git pull --rebase
NEW=`git rev-parse HEAD`

# Test only those files that have changed.
TEST_FILES=$(git diff --name-only $OLD..$NEW | xargs) make xtest
if [ "x$OLD" == "x$NEW" ]; then
echo "No changes to test.";
else
# Test only those files that have changed.
TEST_FILES=$(git diff --name-only $OLD..$NEW | xargs) make xtest
fi

0 comments on commit 9120db3

Please sign in to comment.