-
Notifications
You must be signed in to change notification settings - Fork 2
/
.php-cs-fixer.php
34 lines (30 loc) · 940 Bytes
/
.php-cs-fixer.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
34
<?php
use PhpCsFixer\Finder;
use PhpCsFixer\Config;
$finder = Finder::create()
->in([
'src',
'tests'
]);
$config = new Config();
return $config
->setRules([
'@PSR12' => true,
'strict_param' => true,
'array_syntax' => ['syntax' => 'short'],
'no_trailing_comma_in_singleline_array' => true,
'no_unused_imports' => true,
'trailing_comma_in_multiline' => [
'elements' => ['arrays'],
],
'blank_line_before_statement' => ['statements' => ['return']],
'braces' => [
'position_after_functions_and_oop_constructs' => 'next',
],
'php_unit_construct' => true,
'php_unit_method_casing' => true,
'php_unit_mock_short_will_return' => true,
'php_unit_test_annotation' => true,
'php_unit_test_case_static_method_calls' => ['call_type' => 'this'],
])
->setFinder($finder);