mirror of
https://github.com/php-curl-class/php-curl-class.git
synced 2026-09-03 06:07:05 +00:00
Fix continuous integration tests for PHP 7.1.
There was 1 failure:
1) CurlTest\CurlTest::testRequiredOptionCurlOptReturnTransferEmitsWarning
Failed asserting that exception of type "Error" matches expected exception "\PHPUnit\Framework\Error\Warning".
Message was: "Call to undefined method CurlTest\CurlTest::expectWarning()" at
./tests/PHPCurlClass/PHPCurlClassTest.php:3036
This commit is contained in:
@@ -51,6 +51,11 @@ phpunit_shim() {
|
||||
sed -i'' -e"s/${find}/${replace}/" "$(pwd)/tests/PHPCurlClass/PHP"*
|
||||
}
|
||||
|
||||
phpunit_v7_5_shim() {
|
||||
# Fix "Call to undefined method CurlTest\CurlTest::expectWarning()".
|
||||
sed -i'' -e"/->expectWarning(/d" "$(pwd)/tests/PHPCurlClass/PHPCurlClassTest.php"
|
||||
}
|
||||
|
||||
set -x
|
||||
echo "TRAVIS_PHP_VERSION: ${TRAVIS_PHP_VERSION}"
|
||||
php -r "var_dump(phpversion());"
|
||||
@@ -125,6 +130,7 @@ elif [[ "${TRAVIS_PHP_VERSION}" == "5.6" ]]; then
|
||||
elif [[ "${TRAVIS_PHP_VERSION}" == "7.0" ]]; then
|
||||
php -S 127.0.0.1:8000 -t tests/PHPCurlClass/ &
|
||||
elif [[ "${TRAVIS_PHP_VERSION}" == "7.1" ]]; then
|
||||
phpunit_v7_5_shim
|
||||
php -S 127.0.0.1:8000 -t tests/PHPCurlClass/ &
|
||||
elif [[ "${TRAVIS_PHP_VERSION}" == "7.2" ]]; then
|
||||
php -S 127.0.0.1:8000 -t tests/PHPCurlClass/ &
|
||||
|
||||
Reference in New Issue
Block a user