mirror of
https://github.com/danog/psalm-plugin-phpunit.git
synced 2024-11-26 20:15:08 +01:00
Added failing test for psalm/psalm-plugin-phpunit#102
This commit is contained in:
parent
34e58ff3fe
commit
2480911fb3
@ -1048,6 +1048,26 @@ Feature: TestCase
|
||||
| Type | Message |
|
||||
| InvalidDocblock | %@psalm-force-push-master% |
|
||||
|
||||
Scenario: Missing param type on a test with tuple data provider does not crash psalm
|
||||
Given I have the following code
|
||||
"""
|
||||
class MyTestCase extends TestCase {
|
||||
/**
|
||||
* @dataProvider provide
|
||||
* @psalm-suppress MissingParamType
|
||||
*/
|
||||
public function testSomething($data): void {}
|
||||
|
||||
/** @return iterable<string, array{int}> */
|
||||
public function provide(): iterable {
|
||||
return ['case 1' => [1]];
|
||||
}
|
||||
}
|
||||
"""
|
||||
When I run Psalm
|
||||
Then I see exit code 0
|
||||
And I see no errors
|
||||
|
||||
Scenario: Providers referenced in shorthand docblocks are not marked as unused
|
||||
Given I have the following code
|
||||
"""
|
||||
|
Loading…
Reference in New Issue
Block a user