Skip to content

Commit

Permalink
Delete unused code
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastianbergmann committed Jul 19, 2024
1 parent 4d4375a commit b1742d9
Showing 1 changed file with 0 additions and 30 deletions.
30 changes: 0 additions & 30 deletions src/Framework/MockObject/Runtime/Api/TestDoubleState.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,25 +9,17 @@
*/
namespace PHPUnit\Framework\MockObject;

use function assert;

/**
* @internal This class is not covered by the backward compatibility promise for PHPUnit
*/
final class TestDoubleState
{
/**
* @var array<non-empty-string, true>
*/
private static array $deprecationEmittedForTest = [];

/**
* @var list<ConfigurableMethod>
*/
private readonly array $configurableMethods;
private readonly bool $generateReturnValues;
private ?InvocationHandler $invocationHandler = null;
private ?object $proxyTarget = null;

/**
* @param list<ConfigurableMethod> $configurableMethods
Expand Down Expand Up @@ -65,26 +57,4 @@ public function unsetInvocationHandler(): void
{
$this->invocationHandler = null;
}

public function setProxyTarget(object $proxyTarget): void
{
$this->proxyTarget = $proxyTarget;
}

public function proxyTarget(): object
{
assert($this->proxyTarget !== null);

return $this->proxyTarget;
}

public function deprecationWasEmittedFor(string $testId): void
{
self::$deprecationEmittedForTest[$testId] = true;
}

public function wasDeprecationAlreadyEmittedFor(string $testId): bool
{
return isset(self::$deprecationEmittedForTest[$testId]);
}
}

0 comments on commit b1742d9

Please sign in to comment.