File tree Expand file tree Collapse file tree 2 files changed +6
-12
lines changed
tests/PHPStan/Rules/TooWideTypehints Expand file tree Collapse file tree 2 files changed +6
-12
lines changed Original file line number Diff line number Diff line change @@ -80,7 +80,7 @@ public function testBug13384cPhp82(): void
8080 $ this ->analyse ([__DIR__ . '/data/bug-13384c.php ' ], [
8181 [
8282 'Function Bug13384c\callsReturnsTrue() never returns false so the return type can be changed to true. ' ,
83- 112 ,
83+ 115 ,
8484 ],
8585 ]);
8686 }
@@ -90,16 +90,7 @@ public function testBug13384cPrePhp82(): void
9090 {
9191 $ this ->reportTooWideBool = true ;
9292 $ this ->reportNestedTooWideType = true ;
93- $ this ->analyse ([__DIR__ . '/data/bug-13384c.php ' ], [
94- [
95- 'Function Bug13384c\doFooPhpdoc() never returns false so the return type can be changed to true. ' ,
96- 93 ,
97- ],
98- [
99- 'Function Bug13384c\doFooPhpdoc2() never returns true so the return type can be changed to false. ' ,
100- 100 ,
101- ],
102- ]);
93+ $ this ->analyse ([__DIR__ . '/data/bug-13384c.php ' ], []);
10394 }
10495
10596 public function testBug13384cOff (): void
Original file line number Diff line number Diff line change @@ -105,7 +105,10 @@ function doFooMixed() {
105105 return true ;
106106}
107107
108- function returnsTrue (): true {
108+ /**
109+ * @return true
110+ */
111+ function returnsTrue (): bool {
109112 return true ;
110113}
111114
You can’t perform that action at this time.
0 commit comments