Skip to content

Commit

Permalink
Fix call-sites
Browse files Browse the repository at this point in the history
  • Loading branch information
staabm authored and sebastianbergmann committed Mar 30, 2024
1 parent f121a55 commit 0397f9e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/Framework/TestSuite.php
Expand Up @@ -83,6 +83,7 @@ public static function empty(string $name): static
}

/**
* @psalm-param ReflectionClass<TestCase> $class
* @psalm-param list<non-empty-string> $groups
*/
public static function fromClassReflector(ReflectionClass $class, array $groups = []): static
Expand Down Expand Up @@ -475,14 +476,15 @@ public function sortId(): string
}

/**
* @psalm-assert-if-true class-string $this->name
* @psalm-assert-if-true class-string<TestCase> $this->name
*/
public function isForTestClass(): bool
{
return class_exists($this->name, false) && is_subclass_of($this->name, TestCase::class);
}

/**
* @psalm-param ReflectionClass<TestCase> $class
* @psalm-param list<non-empty-string> $groups
*
* @throws Exception
Expand Down
2 changes: 1 addition & 1 deletion src/Metadata/Api/HookMethods.php
Expand Up @@ -9,10 +9,10 @@
*/
namespace PHPUnit\Metadata\Api;

use PHPUnit\Framework\TestCase;
use function array_unshift;
use function assert;
use function class_exists;
use PHPUnit\Framework\TestCase;
use PHPUnit\Metadata\Parser\Registry;
use PHPUnit\Util\Reflection;
use ReflectionClass;
Expand Down

0 comments on commit 0397f9e

Please sign in to comment.