Skip to content

Commit

Permalink
Add PHPUnit 10+ attributes (#1386)
Browse files Browse the repository at this point in the history
Signed-off-by: Nathanael Esayeas <nathanael.esayeas@protonmail.com>
  • Loading branch information
ghostwriter committed Mar 1, 2024
2 parents 2505d9c + 8123e5c commit e7e2f3f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions library/Mockery/Adapter/Phpunit/MockeryPHPUnitIntegration.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
namespace Mockery\Adapter\Phpunit;

use Mockery;
use PHPUnit\Framework\Attributes\After;
use PHPUnit\Framework\Attributes\Before;

/**
* Integrates Mockery into PHPUnit. Ensures Mockery expectations are verified
Expand Down Expand Up @@ -62,6 +64,7 @@ protected function closeMockery()
/**
* @before
*/
#[Before]

Check failure on line 67 in library/Mockery/Adapter/Phpunit/MockeryPHPUnitIntegration.php

View workflow job for this annotation

GitHub Actions / Psalm

UndefinedAttributeClass

library/Mockery/Adapter/Phpunit/MockeryPHPUnitIntegration.php:67:7: UndefinedAttributeClass: Attribute class PHPUnit\Framework\Attributes\Before does not exist (see https://psalm.dev/241)
protected function startMockery()
{
$this->mockeryOpen = true;
Expand All @@ -70,6 +73,7 @@ protected function startMockery()
/**
* @after
*/
#[After]

Check failure on line 76 in library/Mockery/Adapter/Phpunit/MockeryPHPUnitIntegration.php

View workflow job for this annotation

GitHub Actions / Psalm

UndefinedAttributeClass

library/Mockery/Adapter/Phpunit/MockeryPHPUnitIntegration.php:76:7: UndefinedAttributeClass: Attribute class PHPUnit\Framework\Attributes\After does not exist (see https://psalm.dev/241)
protected function purgeMockeryContainer()
{
if ($this->mockeryOpen) {
Expand Down

0 comments on commit e7e2f3f

Please sign in to comment.