Skip to content

Commit 0e12fee

Browse files
garakJean85
authored andcommitted
add a test matrix to test all Symfony versions (#285)
* add a test matrix to test all Symfony versions * exclude monolog-bundle from version replacement * Remove scrutinizer/ocular from dev dependencies Let's avoid issues while requiring Symfony 5: https://travis-ci.org/getsentry/sentry-symfony/jobs/621355101#L507 * Use Ocular as PHAR
1 parent 578864e commit 0e12fee

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

.travis.yml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ cache:
1414

1515
before_install:
1616
- phpenv config-rm xdebug.ini || echo "Can't disable xDebug"
17+
- |
18+
if [ "$SYMFONY_VERSION" != "" ]; then
19+
sed -ri '/symfony\/monolog-bundle/! s/"symfony\/(.+)": "(.+)"/"symfony\/\1": "'$SYMFONY_VERSION'"/' composer.json;
20+
fi;
1721
- composer self-update
1822
- composer global require hirak/prestissimo
1923

@@ -27,7 +31,12 @@ jobs:
2731
include:
2832
- stage: Test
2933
php: 7.1
30-
name: prefer-lowest
34+
env: SYMFONY_VERSION=3.4.*
35+
- php: 7.3
36+
env: SYMFONY_VERSION=4.4.*
37+
- php: 7.4
38+
env: SYMFONY_VERSION=5.0.*
39+
- name: prefer-lowest
3140
install:
3241
- travis_retry travis_wait composer install --no-interaction --prefer-dist
3342
- composer remove --dev friendsofphp/php-cs-fixer phpstan/phpstan phpstan/phpstan-phpunit jangregor/phpstan-prophecy --no-update
@@ -43,7 +52,8 @@ jobs:
4352
script:
4453
- phpdbg -qrr vendor/bin/phpunit --coverage-clover clover.xml
4554
after_success:
46-
- vendor/bin/ocular code-coverage:upload --format=php-clover clover.xml --revision=$TRAVIS_COMMIT
55+
- wget https://scrutinizer-ci.com/ocular.phar
56+
- php ocular.phar code-coverage:upload --format=php-clover clover.xml --revision=$TRAVIS_COMMIT
4757
allow_failures:
4858
- name: sentry/sentry dev-develop
4959
stage: Test

composer.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@
3737
"phpstan/phpstan-shim": "^0.11",
3838
"phpstan/phpstan-phpunit": "^0.11",
3939
"phpunit/phpunit": "^7.5",
40-
"scrutinizer/ocular": "^1.4",
4140
"symfony/browser-kit": "^3.4||^4.0",
4241
"symfony/expression-language": "^3.4||^4.0",
4342
"symfony/framework-bundle": "^3.4||^4.0",

0 commit comments

Comments
 (0)