From 4dbd704904cdb98898d47ecf24ad560e47a84fcc Mon Sep 17 00:00:00 2001 From: Leo Balter Date: Tue, 11 Apr 2017 13:09:18 -0400 Subject: [PATCH] Update Travis to check for changes after regenerating tests (#965) --- .travis.yml | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 7abb581180..e53ac1328a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,18 @@ language: python install: pip install pyyaml -script: ./make.py -after_success: | +script: | + if [ $TRAVIS_PULL_REQUEST != "false" ]; then + ./make.py clean + fi + echo "PULL_REQUEST: '${TRAVIS_PULL_REQUEST}'" + ./make.py + if [ -n "$(git status --porcelain)" -a $TRAVIS_PULL_REQUEST != "false" ]; then + echo New changes were found after re-generating the tests. + echo Please, read the documentation on procedurally generated tests + echo 'https://github.com/tc39/test262/blob/master/CONTRIBUTING.md#procedurally-generated-tests' + exit 1 + fi +deploy: | if [ $TRAVIS_EVENT_TYPE != "push" -o $TRAVIS_BRANCH != "master" ]; then echo This job is not running against a commit that has been merged to master. echo Skipping deployment.