Skip to content

Commit

Permalink
Move away from phropecy since it is not php8 ready
Browse files Browse the repository at this point in the history
  • Loading branch information
jaapio committed Jul 20, 2020
1 parent eb3320e commit 9781068
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion tests/integration/DocblocksWithAnnotationsTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,6 @@ public function testDocblockWithAnnotationHavingZeroValue(): void
$factory = DocBlockFactory::createInstance();
$docblock = $factory->create($docComment);

$this->assertSame(0, printf('%i', $docblock->getTagsByName('my-tag')));
$this->assertSame(0, (int) $docblock->getTagsByName('my-tag')[0]->render());
}
}
8 changes: 4 additions & 4 deletions tests/unit/DocBlock/StandardTagFactoryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -343,8 +343,8 @@ public function testInvalidTagIsReturnedOnFailure() : void
*/
public function testValidFormattedTags(string $input, string $tagName, string $render) : void
{
$fqsenResolver = $this->prophesize(FqsenResolver::class);
$tagFactory = new StandardTagFactory($fqsenResolver->reveal());
$fqsenResolver = m::mock(FqsenResolver::class);
$tagFactory = new StandardTagFactory($fqsenResolver);
$tagFactory->registerTagHandler('tag', Generic::class);
$tag = $tagFactory->create($input);

Expand Down Expand Up @@ -410,8 +410,8 @@ public function validTagProvider() : array
public function testInValidFormattedTags(string $input) : void
{
$this->expectException(InvalidArgumentException::class);
$fqsenResolver = $this->prophesize(FqsenResolver::class);
$tagFactory = new StandardTagFactory($fqsenResolver->reveal());
$fqsenResolver = m::mock(FqsenResolver::class);
$tagFactory = new StandardTagFactory($fqsenResolver);
$tagFactory->registerTagHandler('tag', Generic::class);
$tagFactory->create($input);
}
Expand Down

0 comments on commit 9781068

Please sign in to comment.