Skip to content

Commit

Permalink
Migrate to phpspec/prophecy-phpunit
Browse files Browse the repository at this point in the history
sebastianbergmann/phpunit#5033 changed phpunit
to no longer depend on phpspec/prophecy. This results in the need to add
a development dependency for phpspec/prophecy. Doing so results in a
warning, since PHPUnit\Framework\TestCase::prophesize() is deprecated
and will be removed in PHPUnit 10. Let's use the trait provided by
phpspec/prophecy-phpunit instead.

* Fixes myclabs#177
  • Loading branch information
athos-ribeiro committed Sep 5, 2022
1 parent 14daed4 commit e03ad06
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
1 change: 1 addition & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
"require-dev": {
"doctrine/collections": "^1.6.8",
"doctrine/common": "^2.13.3 || ^3.2.2",
"phpspec/prophecy-phpunit": "^2.0",
"phpunit/phpunit": "^7.5.20 || ^8.5.23 || ^9.5.13"
},
"conflict": {
Expand Down
5 changes: 3 additions & 2 deletions tests/DeepCopyTest/TypeFilter/Spl/ArrayObjectFilterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
use DeepCopy\DeepCopy;
use DeepCopy\TypeFilter\Spl\ArrayObjectFilter;
use PHPUnit\Framework\TestCase;
use Prophecy\Prophecy\ObjectProphecy;
use Prophecy\PhpUnit\ProphecyTrait;
use RecursiveArrayIterator;

/**
Expand All @@ -16,13 +16,14 @@
*/
final class ArrayObjectFilterTest extends TestCase
{
use ProphecyTrait;
/**
* @var ArrayObjectFilter
*/
private $arrayObjectFilter;

/**
* @var DeepCopy|ObjectProphecy
* @var DeepCopy|ProphecyTrait
*/
private $copierProphecy;

Expand Down

0 comments on commit e03ad06

Please sign in to comment.