Skip to content

Commit c290027

Browse files
Fix generated PHP code formatting (cucumber#46)
Adds `src-generated` folder to the coding style check, and fix the razor template so it passes
1 parent 369809a commit c290027

File tree

3 files changed

+377
-368
lines changed

3 files changed

+377
-368
lines changed

php/.php-cs-fixer.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
$finder = PhpCsFixer\Finder::create()
33
->in([
44
__DIR__ . '/src',
5+
__DIR__ . '/src-generated',
56
__DIR__ . '/tests',
67
__DIR__ . '/bin',
78
])

php/gherkin-php.razor

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -175,8 +175,16 @@ final class @Model.ParserClassName
175175
}
176176
foreach(var production in transition.Productions)
177177
{
178+
if (transition.LookAheadHint != null)
179+
{
180+
<text> </text>
181+
}
178182
@CallProduction(production)
179183
}
184+
if (transition.LookAheadHint != null)
185+
{
186+
<text> </text>
187+
}
180188
@:return @transition.TargetState;
181189
if (transition.LookAheadHint != null)
182190
{

0 commit comments

Comments
 (0)