1
0
mirror of https://github.com/danog/psalm.git synced 2025-01-22 05:41:20 +01:00

bugfix: prevent psalm from yelling about docblock type contradiction

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>
This commit is contained in:
Maximilian Bösing 2021-11-15 18:36:04 +01:00
parent a2bf87b1fc
commit 665cea7fbf
No known key found for this signature in database
GPG Key ID: 9A8988C93CEC81A3

View File

@ -73,6 +73,10 @@ final class ClassConstantByWildcardResolverTest extends TestCase
self::assertCount(1, $resolved);
/** @var non-empty-list<\Psalm\Type\Atomic> $type */
$type = $resolved[0];
/**
* @psalm-suppress DocblockTypeContradiction TLiteralString has to be asserted here,
* ofc it does not match the docblock
*/
self::assertInstanceOf(TLiteralString::class, $type);
self::assertTrue($type->value === 'qoo');
}