diff --git a/.scrutinizer.yml b/.scrutinizer.yml index 1a7b472..925a7d2 100644 --- a/.scrutinizer.yml +++ b/.scrutinizer.yml @@ -3,7 +3,7 @@ inherit: true build: environment: php: - version: 7.2 + version: 7.4 tests: override: - make test diff --git a/.travis.yml b/.travis.yml index 79d3e51..8acb904 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,11 +1,11 @@ language: php matrix: include: - - php: 7.2 - env: EXECUTE_DEPLOYMENT=true - php: 7.3 - env: deps=low + env: EXECUTE_DEPLOYMENT=true - php: 7.4 + - php: 7.4 + env: deps=low fast_finish: true before_install: - phpenv config-rm xdebug.ini || echo "XDebug is not enabled" diff --git a/Makefile b/Makefile index bc6a906..c01fd98 100644 --- a/Makefile +++ b/Makefile @@ -75,7 +75,7 @@ package: tools/box cd build/phar && \ composer remove phpunit/phpunit --no-update && \ - composer config platform.php 7.2 && \ + composer config platform.php 7.3 && \ composer update --no-dev -o -a tools/box compile @@ -97,16 +97,16 @@ tools/deptrac: curl -Ls http://get.sensiolabs.de/deptrac.phar -o tools/deptrac && chmod +x tools/deptrac tools/infection: tools/infection.pubkey - curl -Ls https://github.com/infection/infection/releases/download/0.13.2/infection.phar -o tools/infection && chmod +x tools/infection + curl -Ls https://github.com/infection/infection/releases/download/0.16.1/infection.phar -o tools/infection && chmod +x tools/infection tools/infection.pubkey: - curl -Ls https://github.com/infection/infection/releases/download/0.13.2/infection.phar.pubkey -o tools/infection.pubkey + curl -Ls https://github.com/infection/infection/releases/download/0.16.1/infection.phar.pubkey -o tools/infection.pubkey tools/box: curl -Ls https://github.com/humbug/box/releases/download/3.8.4/box.phar -o tools/box && chmod +x tools/box tests/phar/tools/phpunit: - curl -Ls https://phar.phpunit.de/phpunit-8.phar -o tests/phar/tools/phpunit && chmod +x tests/phar/tools/phpunit + curl -Ls https://phar.phpunit.de/phpunit-9.phar -o tests/phar/tools/phpunit && chmod +x tests/phar/tools/phpunit tests/phar/tools/phpunit.d/zalas-phpunit-doubles-extension.phar: build/zalas-phpunit-doubles-extension.phar cp build/zalas-phpunit-doubles-extension.phar tests/phar/tools/phpunit.d/zalas-phpunit-doubles-extension.phar diff --git a/composer.json b/composer.json index a378fe7..9d11438 100644 --- a/composer.json +++ b/composer.json @@ -3,11 +3,12 @@ "description": "Initialises test doubles in PHPUnit test cases for you", "type": "library", "require": { - "php": "^7.2,<8.0", - "phpunit/phpunit": "^8.5 || ^9.0", + "php": "^7.3,<8.0", + "phpunit/phpunit": "^9.1", "phpdocumentor/reflection-docblock": "^4.0.1" }, "require-dev": { + "phpspec/prophecy-phpunit": "dev-master" }, "autoload": { "psr-4": { diff --git a/manifest.xml.in b/manifest.xml.in index 7fccb8a..dfd4202 100644 --- a/manifest.xml.in +++ b/manifest.xml.in @@ -10,6 +10,6 @@ - + diff --git a/tests/TestCase/TestDoubles/Inheritance/InheritanceTest.php b/tests/TestCase/TestDoubles/Inheritance/InheritanceTest.php index 7775bf7..ab5bdd7 100644 --- a/tests/TestCase/TestDoubles/Inheritance/InheritanceTest.php +++ b/tests/TestCase/TestDoubles/Inheritance/InheritanceTest.php @@ -3,6 +3,7 @@ namespace Zalas\PHPUnit\Doubles\Tests\TestCase\TestDoubles\Inheritance; +use Prophecy\PhpUnit\ProphecyTrait; use Prophecy\Prophecy\ObjectProphecy; use Zalas\PHPUnit\Doubles\TestCase\TestDoubles; use Zalas\PHPUnit\Doubles\Tests\TestCase\TestDoubles\Fixtures\Fred; @@ -10,6 +11,7 @@ class InheritanceTest extends BaseTestCase { + use ProphecyTrait; use TestDoubles; use PropertyTrait; diff --git a/tests/TestCase/TestDoubles/MissingType/ProphecyTest.php b/tests/TestCase/TestDoubles/MissingType/ProphecyTest.php index 90b856e..ce820a1 100644 --- a/tests/TestCase/TestDoubles/MissingType/ProphecyTest.php +++ b/tests/TestCase/TestDoubles/MissingType/ProphecyTest.php @@ -4,11 +4,13 @@ namespace Zalas\PHPUnit\Doubles\Tests\TestCase\TestDoubles\MissingType; use PHPUnit\Framework\TestCase; +use Prophecy\PhpUnit\ProphecyTrait; use Prophecy\Prophecy\ObjectProphecy; use Zalas\PHPUnit\Doubles\TestCase\TestDoubles; class ProphecyTest extends TestCase { + use ProphecyTrait; use TestDoubles; /** diff --git a/tests/TestCase/TestDoubles/NotNull/ProphecyTest.php b/tests/TestCase/TestDoubles/NotNull/ProphecyTest.php index e2806cd..32bf29c 100644 --- a/tests/TestCase/TestDoubles/NotNull/ProphecyTest.php +++ b/tests/TestCase/TestDoubles/NotNull/ProphecyTest.php @@ -4,6 +4,7 @@ namespace Zalas\PHPUnit\Doubles\Tests\TestCase\TestDoubles\NotNull; use PHPUnit\Framework\TestCase; +use Prophecy\PhpUnit\ProphecyTrait; use Prophecy\Prophecy\ObjectProphecy; use Zalas\PHPUnit\Doubles\TestCase\TestDoubles; use Zalas\PHPUnit\Doubles\Tests\TestCase\TestDoubles\Fixtures\Copper; @@ -12,6 +13,7 @@ class ProphecyTest extends TestCase { + use ProphecyTrait; use TestDoubles; /** diff --git a/tests/TestCase/TestDoubles/ProphecyTest.php b/tests/TestCase/TestDoubles/ProphecyTest.php index 7535089..5b8653a 100644 --- a/tests/TestCase/TestDoubles/ProphecyTest.php +++ b/tests/TestCase/TestDoubles/ProphecyTest.php @@ -4,6 +4,7 @@ namespace Zalas\PHPUnit\Doubles\Tests\TestCase\TestDoubles; use PHPUnit\Framework\TestCase; +use Prophecy\PhpUnit\ProphecyTrait; use Prophecy\Prophecy\ObjectProphecy; use Zalas\PHPUnit\Doubles\TestCase\TestDoubles; use Zalas\PHPUnit\Doubles\Tests\TestCase\TestDoubles\Fixtures\Copper; @@ -16,6 +17,7 @@ class ProphecyTest extends TestCase { + use ProphecyTrait; use TestDoubles; /**