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

Add skipped test;

This commit is contained in:
Brown 2019-03-07 18:25:48 -05:00
parent 5beb26659e
commit 94b1161a80

View File

@ -1711,6 +1711,32 @@ class TemplateTest extends TestCase
*/
function bar(Foo $a) : void {}'
],
'SKIPPED-templateDefault' => [
'<?php
/**
* @template T as string
*/
class C {
/** @var T */
public $t;
/**
* @param T $t
*/
function __construct(string $t = "hello") {
$this->t = $t;
}
}
$a = new C("hello");
$b = new C("goodbye");
$c = new C();',
'assertions' => [
'$a===' => 'C<string(hello)>',
'$b===' => 'C<string(goodbye)>',
'$c===' => 'C<string(hello)>',
],
],
];
}