CodeStylePatcher::patch()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 5
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 4
c 1
b 0
f 0
nc 1
nop 1
dl 0
loc 7
ccs 5
cts 5
cp 1
crap 1
rs 10
1
<?php
2
3
/**
4
 * Copyright MediaCT. All rights reserved.
5
 * https://www.mediact.nl
6
 */
7
8
declare(strict_types=1);
9
10
namespace Mediact\CodingStandard\PhpStorm\Patcher;
11
12
use Mediact\CodingStandard\PhpStorm\EnvironmentInterface;
13
14
class CodeStylePatcher implements ConfigPatcherInterface
15
{
16
    use CopyFilesTrait;
17
18
    /**
19
     * Patch the config.
20
     *
21
     * @param EnvironmentInterface $environment
22
     *
23
     * @return void
24
     */
25 1
    public function patch(
26
        EnvironmentInterface $environment
27
    ): void {
28 1
        $this->copyFile(
29 1
            $environment->getDefaultsFilesystem(),
30 1
            $environment->getIdeConfigFilesystem(),
31 1
            'codeStyleSettings.xml'
32
        );
33 1
    }
34
}
35