-
Notifications
You must be signed in to change notification settings - Fork 8
/
ecs-internal.php
33 lines (31 loc) · 1.13 KB
/
ecs-internal.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
<?php declare(strict_types=1);
use PHP_CodeSniffer\Standards\Generic\Sniffs\PHP\ForbiddenFunctionsSniff;
use PhpCsFixer\Fixer\ClassNotation\ClassAttributesSeparationFixer;
use PhpCsFixer\Fixer\PhpUnit\PhpUnitTestAnnotationFixer;
use Symplify\CodingStandard\Fixer\LineLength\LineLengthFixer;
use Symplify\EasyCodingStandard\Config\ECSConfig;
/*
* Internal rules configuration for the lmc/coding-standard project itself
*/
return ECSConfig::configure()
->withPaths([__DIR__ . '/src', __DIR__ . '/tests'])
->withRootFiles()
->withSets(
[
__DIR__ . '/ecs.php',
],
)
->withConfiguredRule(PhpUnitTestAnnotationFixer::class, ['style' => 'annotation'])
->withConfiguredRule(
LineLengthFixer::class,
['line_length' => 120, 'break_long_lines' => true, 'inline_short_lines' => false],
)
->withConfiguredRule(
ClassAttributesSeparationFixer::class,
['elements' => ['const' => 'none', 'method' => 'one', 'property' => 'none']],
)
->withSkip(
[
ForbiddenFunctionsSniff::class => ['tests/Integration/CodingStandardTest.php'],
],
);