minor #33673 [travis] more CI fixes (nicolas-grekas)
This PR was merged into the 3.4 branch.
Discussion
----------
[travis] more CI fixes
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | no
| Deprecations? | no
| Tickets | -
| License | MIT
| Doc PR | -
Commits
-------
27b1986cc2
[travis] more CI fixes
This commit is contained in:
commit
2bfef232e0
12
.travis.yml
12
.travis.yml
@ -170,7 +170,6 @@ before_install:
|
|||||||
if [[ $PHP = hhvm* ]]; then
|
if [[ $PHP = hhvm* ]]; then
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
export PHP=$PHP
|
|
||||||
phpenv global $PHP
|
phpenv global $PHP
|
||||||
INI=~/.phpenv/versions/$PHP/etc/conf.d/travis.ini
|
INI=~/.phpenv/versions/$PHP/etc/conf.d/travis.ini
|
||||||
if [[ $PHP = 5.* ]]; then
|
if [[ $PHP = 5.* ]]; then
|
||||||
@ -205,7 +204,7 @@ install:
|
|||||||
git fetch --depth=2 origin refs/pull/$SYMFONY_PHPUNIT_BRIDGE_PR/head
|
git fetch --depth=2 origin refs/pull/$SYMFONY_PHPUNIT_BRIDGE_PR/head
|
||||||
git rm -rq src/Symfony/Bridge/PhpUnit
|
git rm -rq src/Symfony/Bridge/PhpUnit
|
||||||
git checkout -q FETCH_HEAD -- src/Symfony/Bridge/PhpUnit
|
git checkout -q FETCH_HEAD -- src/Symfony/Bridge/PhpUnit
|
||||||
SYMFONY_VERSION=$(cat src/Symfony/Bridge/PhpUnit/composer.json | grep '^ *"dev-master". *"[1-9]' | grep -o '[0-9.]*')
|
export SYMFONY_VERSION=$(cat src/Symfony/Bridge/PhpUnit/composer.json | grep '^ *"dev-master". *"[1-9]' | grep -o '[0-9.]*')
|
||||||
sed -i 's/"symfony\/phpunit-bridge": ".*"/"symfony\/phpunit-bridge": "'$SYMFONY_VERSION'.x@dev"/' composer.json
|
sed -i 's/"symfony\/phpunit-bridge": ".*"/"symfony\/phpunit-bridge": "'$SYMFONY_VERSION'.x@dev"/' composer.json
|
||||||
rm -rf .phpunit
|
rm -rf .phpunit
|
||||||
fi
|
fi
|
||||||
@ -218,7 +217,7 @@ install:
|
|||||||
export SYMFONY_DEPRECATIONS_HELPER=weak &&
|
export SYMFONY_DEPRECATIONS_HELPER=weak &&
|
||||||
cp composer.json composer.json.orig &&
|
cp composer.json composer.json.orig &&
|
||||||
echo -e '{\n"require":{'"$(grep phpunit-bridge composer.json)"'"php":"*"},"minimum-stability":"dev"}' > composer.json &&
|
echo -e '{\n"require":{'"$(grep phpunit-bridge composer.json)"'"php":"*"},"minimum-stability":"dev"}' > composer.json &&
|
||||||
php .github/build-packages.php HEAD^ $(find src/Symfony -mindepth 3 -type f -name composer.json -printf '%h\n') &&
|
php .github/build-packages.php HEAD^ $(find src/Symfony -mindepth 3 -type f -name composer.json -printf '%h\n' | sort) &&
|
||||||
mv composer.json composer.json.phpunit &&
|
mv composer.json composer.json.phpunit &&
|
||||||
mv composer.json.orig composer.json
|
mv composer.json.orig composer.json
|
||||||
fi
|
fi
|
||||||
@ -231,12 +230,12 @@ install:
|
|||||||
# For the master branch, when deps=high, the version before master is checked out and tested with the locally patched components
|
# For the master branch, when deps=high, the version before master is checked out and tested with the locally patched components
|
||||||
if [[ $deps = high && $TRAVIS_BRANCH = master ]]; then
|
if [[ $deps = high && $TRAVIS_BRANCH = master ]]; then
|
||||||
export FLIP='🙃'
|
export FLIP='🙃'
|
||||||
SYMFONY_VERSION=$(git ls-remote --heads | grep -o '/[1-9].*' | tail -n 1 | sed s/.//) &&
|
export SYMFONY_VERSION=$(git ls-remote --heads | grep -o '/[1-9].*' | tail -n 1 | sed s/.//) &&
|
||||||
git fetch --depth=2 origin $SYMFONY_VERSION &&
|
git fetch --depth=2 origin $SYMFONY_VERSION &&
|
||||||
git checkout -m FETCH_HEAD &&
|
git checkout -m FETCH_HEAD &&
|
||||||
export COMPONENTS=$(find src/Symfony -mindepth 3 -type f -name phpunit.xml.dist -printf '%h\n' | sort)
|
export COMPONENTS=$(find src/Symfony -mindepth 3 -type f -name phpunit.xml.dist -printf '%h\n' | sort)
|
||||||
else
|
else
|
||||||
SYMFONY_VERSION=$(cat composer.json | grep '^ *"dev-master". *"[1-9]' | grep -o '[0-9.]*')
|
export SYMFONY_VERSION=$(cat composer.json | grep '^ *"dev-master". *"[1-9]' | grep -o '[0-9.]*')
|
||||||
fi
|
fi
|
||||||
|
|
||||||
- |
|
- |
|
||||||
@ -268,7 +267,7 @@ install:
|
|||||||
- |
|
- |
|
||||||
run_tests () {
|
run_tests () {
|
||||||
set -e
|
set -e
|
||||||
export PHP=$1
|
PHP=$1
|
||||||
if [[ $PHP != $TRAVIS_PHP_VERSION && $TRAVIS_PULL_REQUEST != false ]]; then
|
if [[ $PHP != $TRAVIS_PHP_VERSION && $TRAVIS_PULL_REQUEST != false ]]; then
|
||||||
echo -e "\\n\\e[33;1mIntermediate PHP version $PHP is skipped for pull requests.\\e[0m"
|
echo -e "\\n\\e[33;1mIntermediate PHP version $PHP is skipped for pull requests.\\e[0m"
|
||||||
return
|
return
|
||||||
@ -298,7 +297,6 @@ install:
|
|||||||
echo "$COMPONENTS" | parallel --gnu "tfold {} $PHPUNIT_X {}"
|
echo "$COMPONENTS" | parallel --gnu "tfold {} $PHPUNIT_X {}"
|
||||||
tfold src/Symfony/Component/Console.tty $PHPUNIT src/Symfony/Component/Console --group tty
|
tfold src/Symfony/Component/Console.tty $PHPUNIT src/Symfony/Component/Console --group tty
|
||||||
if [[ $PHP = ${MIN_PHP%.*} ]]; then
|
if [[ $PHP = ${MIN_PHP%.*} ]]; then
|
||||||
export PHP=$MIN_PHP
|
|
||||||
echo -e "1\\n0" | xargs -I{} bash -c "tfold src/Symfony/Component/Process.sigchild{} SYMFONY_DEPRECATIONS_HELPER=weak ENHANCE_SIGCHLD={} php-$MIN_PHP/sapi/cli/php .phpunit/phpunit-4.8-1/phpunit --colors=always src/Symfony/Component/Process/"
|
echo -e "1\\n0" | xargs -I{} bash -c "tfold src/Symfony/Component/Process.sigchild{} SYMFONY_DEPRECATIONS_HELPER=weak ENHANCE_SIGCHLD={} php-$MIN_PHP/sapi/cli/php .phpunit/phpunit-4.8-1/phpunit --colors=always src/Symfony/Component/Process/"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
Reference in New Issue
Block a user