Skip to content
This repository was archived by the owner on Oct 6, 2023. It is now read-only.

Commit 761373a

Browse files
kubawerloskeradus
authored andcommitted
Support PHPUnit 8 (#41)
1 parent 88c8918 commit 761373a

File tree

3 files changed

+10
-1
lines changed

3 files changed

+10
-1
lines changed

.travis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ script:
6161
- ./run-tests.sh ~7.3.0 || travis_terminate 1
6262
- ./run-tests.sh ~7.4.0 || travis_terminate 1
6363
- ./run-tests.sh ~7.5.0 || travis_terminate 1
64+
- ./run-tests.sh ~8.0.0 || travis_terminate 1
6465

6566
jobs:
6667
include:

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
],
1212
"require": {
1313
"php": "^5.5 || ^7.0",
14-
"phpunit/phpunit": "~4.0.0 || ~4.1.0 || ~4.2.0 || ~4.3.0 || ~4.4.0 || ~4.5.0 || ~4.6.0 || ~4.8.0 || ~5.3.0 || ~5.4.0 || ~5.5.0 || ~5.6.0 || ~5.7.0 || ~6.0.0 || ~6.1.0 || ~6.2.0 || ~6.3.0 || ~6.4.0 || ~6.5.0 || ~7.0.0 || ~7.1.0 || ~7.2.6 || ~7.3.0 || ~7.4.0 || ~7.5.0"
14+
"phpunit/phpunit": "~4.0.0 || ~4.1.0 || ~4.2.0 || ~4.3.0 || ~4.4.0 || ~4.5.0 || ~4.6.0 || ~4.8.0 || ~5.3.0 || ~5.4.0 || ~5.5.0 || ~5.6.0 || ~5.7.0 || ~6.0.0 || ~6.1.0 || ~6.2.0 || ~6.3.0 || ~6.4.0 || ~6.5.0 || ~7.0.0 || ~7.1.0 || ~7.2.6 || ~7.3.0 || ~7.4.0 || ~7.5.0 || ~8.0.0"
1515
},
1616
"conflict": {
1717
"hhvm": "*"

run-tests.sh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,15 @@ echo -e "\e[46m§ Trying to execute tests under PHPUnit ${PHPUNIT}.\e[0m"
1515
rm -f composer.lock
1616

1717
echo -e "\n\e[46m§ Installing deps...\e[0m"
18+
if [ ${PHPUNIT:1:1} == 8 ]
19+
then
20+
composer require -q --dev --no-update friendsofphp/php-cs-fixer || return 0
21+
fi
1822
composer require -q --dev --no-update phpunit/phpunit:${PHPUNIT} && composer update -q $DEFAULT_COMPOSER_FLAGS && INSTALLED=1 || INSTALLED=0
23+
if [ $INSTALLED == 1 ] && [ ${PHPUNIT:1:1} == 8 ]
24+
then
25+
PHP_CS_FIXER_FUTURE_MODE=1 vendor/bin/php-cs-fixer fix --rules=void_return -q tests
26+
fi
1927
git checkout composer.json
2028

2129
if [ $INSTALLED == 0 ]

0 commit comments

Comments
 (0)