Skip to content

Commit 82d790b

Browse files
author
David Alger
committed
Merge branch 'feature/update-travis' into feature/responsive-email-structure
2 parents 264c224 + 7ae017d commit 82d790b

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

.travis.yml

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,16 @@ matrix:
2323
before_install:
2424
- sudo apt-get update -qq
2525
- sudo apt-get install -y -qq postfix
26-
- sh -c "if [ -x $HOME/.cache/bin/composer ]; then $HOME/.cache/bin/composer self-update; echo ''; else mkdir -p $HOME/.cache/bin; curl --connect-timeout 30 -sS 'https://getcomposer.org/installer' | php -- --install-dir $HOME/.cache/bin/ --filename composer; fi"
27-
- $HOME/.cache/bin/composer --version
26+
- sh -c 'if [ "$CASHER_DIR" ]; then
27+
if [ -x $HOME/.cache/bin/composer ]; then
28+
$HOME/.cache/bin/composer self-update; echo '';
29+
else
30+
mkdir -p $HOME/.cache/bin;
31+
curl --connect-timeout 30 -sS https://getcomposer.org/installer \
32+
| php -- --install-dir $HOME/.cache/bin/ --filename composer;
33+
fi
34+
fi'
35+
- export PATH="$HOME/.cache/bin:$PATH"
2836
before_script:
2937
# Mock mail
3038
- sudo service postfix stop
@@ -53,7 +61,7 @@ before_script:
5361
# Change memory_limit for travis
5462
- echo 'memory_limit = -1' >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
5563
- phpenv rehash;
56-
- $HOME/.cache/bin/composer install --no-interaction --prefer-dist
64+
- composer install --no-interaction --prefer-dist
5765
script:
5866
# Unit tests
5967
- sh -c "if [ '$TEST_SUITE' = 'unit' ]; then ./vendor/bin/phpunit -c dev/tests/unit/phpunit.xml.dist; fi"
@@ -66,4 +74,4 @@ script:
6674
# Static tests [Code Style]
6775
- sh -c "if [ '$TEST_SUITE' = 'static_phpcs' ]; then cd dev/tests/static; ./../../../vendor/bin/phpunit -c phpunit.xml.dist --filter 'Magento\\\\Test\\\\Php\\\\LiveCodeTest::testCodeStyle'; fi"
6876
# Static tests [Code Style]
69-
- sh -c "if [ '$TEST_SUITE' = 'static_annotation' ]; then cd dev/tests/static; ./../../../vendor/bin/phpunit -c phpunit.xml.dist --filter 'Magento\\\\Test\\\\Php\\\\LiveCodeTest::testAnnotationStandard'; fi"
77+
- sh -c "if [ '$TEST_SUITE' = 'static_annotation' ]; then cd dev/tests/static; ./../../../vendor/bin/phpunit -c phpunit.xml.dist --filter 'Magento\\\\Test\\\\Php\\\\LiveCodeTest::testAnnotationStandard'; fi"

0 commit comments

Comments
 (0)