Skip to content

Commit

Permalink
Update travis build
Browse files Browse the repository at this point in the history
Simplified test method for compatibility with older PHPUnit versions.
  • Loading branch information
trowski committed Mar 3, 2020
1 parent ab6f98b commit 57e38b6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
12 changes: 7 additions & 5 deletions .travis.yml
@@ -1,14 +1,16 @@
sudo: false
os: linux

language: php

php:
- 7.0
- 7.1
- 7.2
- 7.3
- 7.4
- nightly

matrix:
jobs:
allow_failures:
- php: nightly
fast_finish: true
Expand All @@ -27,12 +29,12 @@ before_install:

install:
- composer update -n --prefer-dist
- wget https://github.com/php-coveralls/php-coveralls/releases/download/v1.0.2/coveralls.phar
- chmod +x coveralls.phar

script:
- phpdbg -qrr vendor/bin/phpunit --coverage-text --coverage-clover build/logs/clover.xml
- PHP_CS_FIXER_IGNORE_ENV=1 php vendor/bin/php-cs-fixer --diff --dry-run -v fix

after_script:
- ./coveralls.phar
- wget https://github.com/php-coveralls/php-coveralls/releases/download/v2.2.0/php-coveralls.phar
- chmod +x php-coveralls.phar
- travis_retry ./php-coveralls.phar -v
2 changes: 1 addition & 1 deletion test/RetryConnectorTest.php
Expand Up @@ -68,7 +68,7 @@ public function testFailingConnect(): \Generator
->getMockForAbstractClass();

$this->expectException(ConnectionException::class);
$this->expectExceptionMessageMatches('/Could not connect to database server at (.+):\d+ after \d+ tries/');
$this->expectExceptionMessage('Could not connect to database server');

$connection = yield $retry->connect($config);
}
Expand Down

0 comments on commit 57e38b6

Please sign in to comment.