Skip to content

Commit a570ffd

Browse files
authored
Discard changes to tests/PHPStan/Rules/TooWideTypehints/TooWideMethodReturnTypehintRuleTest.php
1 parent d2efaab commit a570ffd

File tree

1 file changed

+36
-2
lines changed

1 file changed

+36
-2
lines changed

tests/PHPStan/Rules/TooWideTypehints/TooWideMethodReturnTypehintRuleTest.php

Lines changed: 36 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -230,15 +230,49 @@ public function testBug13384c(): void
230230
{
231231
$this->reportTooWideBool = true;
232232
$this->reportNestedTooWideType = true;
233-
$this->analyse([__DIR__ . '/data/bug-13384c.php'], []);
233+
$this->analyse([__DIR__ . '/data/bug-13384c.php'], [
234+
[
235+
'Method Bug13384c\Bug13384c::doBar() never returns true so the return type can be changed to false.',
236+
33,
237+
],
238+
[
239+
'Method Bug13384c\Bug13384c::doBar2() never returns false so the return type can be changed to true.',
240+
37,
241+
],
242+
[
243+
'Method Bug13384c\Bug13384c::doBarPhpdoc() never returns false so the return type can be changed to true.',
244+
55,
245+
],
246+
[
247+
'Method Bug13384c\Bug13384Static::doBar() never returns true so the return type can be changed to false.',
248+
62,
249+
],
250+
[
251+
'Method Bug13384c\Bug13384Static::doBar2() never returns false so the return type can be changed to true.',
252+
66,
253+
],
254+
[
255+
'Method Bug13384c\Bug13384Static::doBarPhpdoc() never returns false so the return type can be changed to true.',
256+
84,
257+
],
258+
]);
234259
}
235260

236261
#[RequiresPhp('< 8.2')]
237262
public function testBug13384cPrePhp82(): void
238263
{
239264
$this->reportTooWideBool = true;
240265
$this->reportNestedTooWideType = true;
241-
$this->analyse([__DIR__ . '/data/bug-13384c.php'], []);
266+
$this->analyse([__DIR__ . '/data/bug-13384c.php'], [
267+
[
268+
'Method Bug13384c\Bug13384c::doBarPhpdoc() never returns false so the return type can be changed to true.',
269+
55,
270+
],
271+
[
272+
'Method Bug13384c\Bug13384Static::doBarPhpdoc() never returns false so the return type can be changed to true.',
273+
84,
274+
],
275+
]);
242276
}
243277

244278
public function testBug13384cOff(): void

0 commit comments

Comments
 (0)