mirror of
https://github.com/danog/psalm.git
synced 2025-01-22 05:41:20 +01:00
add test
This commit is contained in:
parent
80f617decd
commit
9877517284
@ -699,6 +699,24 @@ class ArgTest extends TestCase
|
|||||||
',
|
',
|
||||||
'error_message' => 'ArgumentTypeCoercion',
|
'error_message' => 'ArgumentTypeCoercion',
|
||||||
],
|
],
|
||||||
|
'MissingMandatoryParamWithNamedParams' => [
|
||||||
|
'<?php
|
||||||
|
class User
|
||||||
|
{
|
||||||
|
public function __construct(
|
||||||
|
protected string $name,
|
||||||
|
protected string $problematicOne,
|
||||||
|
protected string $id = "",
|
||||||
|
){}
|
||||||
|
}
|
||||||
|
|
||||||
|
new User(
|
||||||
|
name: "John",
|
||||||
|
id: "asd",
|
||||||
|
);
|
||||||
|
',
|
||||||
|
'error_message' => 'TooFewArguments',
|
||||||
|
],
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user