File tree Expand file tree Collapse file tree 2 files changed +22
-22
lines changed
src/Command/ErrorFormatter
tests/PHPStan/Command/ErrorFormatter Expand file tree Collapse file tree 2 files changed +22
-22
lines changed Original file line number Diff line number Diff line change @@ -84,7 +84,7 @@ public function formatErrors(
84
84
$ filePath = $ error ->getTraitFilePath () ?? $ error ->getFilePath ();
85
85
if ($ error ->getIdentifier () !== null && $ error ->canBeIgnored ()) {
86
86
$ message .= "\n" ;
87
- $ message .= '🪪 ' . $ error ->getIdentifier ();
87
+ $ message .= '🪪 ' . $ error ->getIdentifier ();
88
88
}
89
89
if ($ error ->getTip () !== null ) {
90
90
$ tip = $ error ->getTip ();
@@ -94,11 +94,11 @@ public function formatErrors(
94
94
if (str_contains ($ tip , "\n" )) {
95
95
$ lines = explode ("\n" , $ tip );
96
96
foreach ($ lines as $ line ) {
97
- $ message .= '💡 ' . ltrim ($ line , ' • ' ) . "\n" ;
97
+ $ message .= '💡 ' . ltrim ($ line , ' • ' ) . "\n" ;
98
98
}
99
99
$ message = rtrim ($ message , "\n" );
100
100
} else {
101
- $ message .= '💡 ' . $ tip ;
101
+ $ message .= '💡 ' . $ tip ;
102
102
}
103
103
}
104
104
if (is_string ($ this ->editorUrl )) {
@@ -118,7 +118,7 @@ public function formatErrors(
118
118
$ title = $ this ->relativePathHelper ->getRelativePath ($ filePath );
119
119
}
120
120
121
- $ message .= "\n✏️ <href= " . OutputFormatter::escape ($ url ) . '> ' . $ title . '</> ' ;
121
+ $ message .= "\n✏️ <href= " . OutputFormatter::escape ($ url ) . '> ' . $ title . '</> ' ;
122
122
}
123
123
124
124
if (
Original file line number Diff line number Diff line change @@ -94,14 +94,14 @@ public function dataFormatterOutputProvider(): iterable
94
94
4 Foo
95
95
------ -------------------------------------------------------------------
96
96
97
- ------ ----------
97
+ ------ -----------
98
98
Line foo.php
99
- ------ ----------
99
+ ------ -----------
100
100
1 Foo<Bar>
101
101
5 Bar
102
102
Bar2
103
- 💡 a tip
104
- ------ ----------
103
+ 💡 a tip
104
+ ------ -----------
105
105
106
106
[ERROR] Found 4 errors
107
107
@@ -143,14 +143,14 @@ public function dataFormatterOutputProvider(): iterable
143
143
4 Foo
144
144
------ -------------------------------------------------------------------
145
145
146
- ------ ----------
146
+ ------ -----------
147
147
Line foo.php
148
- ------ ----------
148
+ ------ -----------
149
149
1 Foo<Bar>
150
150
5 Bar
151
151
Bar2
152
- 💡 a tip
153
- ------ ----------
152
+ 💡 a tip
153
+ ------ -----------
154
154
155
155
-- -----------------------
156
156
Error
@@ -190,13 +190,13 @@ public function dataFormatterOutputProvider(): iterable
190
190
'numGenericErrors ' => 0 ,
191
191
'verbose ' => false ,
192
192
'extraEnvVars ' => [],
193
- 'expected ' => ' ------ ---------------
193
+ 'expected ' => ' ------ ----------------
194
194
Line foo.php
195
- ------ ---------------
195
+ ------ ----------------
196
196
5 Foobar\Buz
197
- 🪪 foobar.buz
198
- 💡 a tip
199
- ------ ---------------
197
+ 🪪 foobar.buz
198
+ 💡 a tip
199
+ ------ ----------------
200
200
201
201
202
202
[ERROR] Found 1 error
@@ -211,13 +211,13 @@ public function dataFormatterOutputProvider(): iterable
211
211
'numGenericErrors ' => 0 ,
212
212
'verbose ' => true ,
213
213
'extraEnvVars ' => [],
214
- 'expected ' => ' ------ ---------------
214
+ 'expected ' => ' ------ ----------------
215
215
Line foo.php
216
- ------ ---------------
216
+ ------ ----------------
217
217
5 Foobar\Buz
218
- 🪪 foobar.buz
219
- 💡 a tip
220
- ------ ---------------
218
+ 🪪 foobar.buz
219
+ 💡 a tip
220
+ ------ ----------------
221
221
222
222
223
223
[ERROR] Found 1 error
You can’t perform that action at this time.
0 commit comments