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:
parent
f8c225c576
commit
c312c76050
@ -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",
|
||||
],
|
||||
],
|
||||
],
|
||||
],
|
||||
];
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user