1
0
mirror of https://github.com/danog/psalm.git synced 2024-11-30 04:39:00 +01:00

chore: add test

This commit is contained in:
ging-dev 2023-09-30 17:33:50 +07:00
parent f8c225c576
commit c312c76050

View File

@ -199,5 +199,54 @@ class CacheTest extends TestCase
],
],
];
yield 'classDocblockChange' => [
[
[
'files' => [
'/src/A.php' => <<<'PHP'
<?php
/**
* @template T
*/
class A {
/**
* @param T $baz
*/
public function foo($baz): void
{
}
}
PHP,
],
'issues' => [],
],
[
'files' => [
'/src/A.php' => <<<'PHP'
<?php
/**
* @template K
*/
class A {
/**
* @param T $baz
*/
public function foo($baz): void
{
}
}
PHP,
],
'issues' => [
'/src/A.php' => [
"UndefinedDocblockClass: Docblock-defined class, interface or enum named T does not exist",
],
],
],
],
];
}
}