Conditions | 2 |
Paths | 1 |
Total Lines | 29 |
Code Lines | 22 |
Lines | 0 |
Ratio | 0 % |
Tests | 23 |
CRAP Score | 2 |
Changes | 0 |
1 | <?php |
||
38 | 45 | protected function _check(NodeDefinition $node): NodeDefinition |
|
39 | { |
||
40 | $node = $node |
||
41 | 45 | ->children() |
|
42 | 45 | ->arrayNode('check') |
|
43 | 45 | ->children() |
|
44 | 45 | ->arrayNode('files') |
|
45 | 45 | ->isRequired() |
|
46 | 45 | ->beforeNormalization() |
|
47 | 45 | ->ifString() |
|
48 | 45 | ->then(static function ($value) { |
|
49 | 1 | if (\is_string($value)) { |
|
50 | 1 | $value = [$value]; |
|
51 | } |
||
52 | |||
53 | 1 | return $value; |
|
54 | 45 | }) |
|
55 | 45 | ->end() |
|
56 | 45 | ->prototype('scalar')->end() |
|
57 | 45 | ->end() |
|
58 | 45 | ->end() |
|
59 | 45 | ->end() |
|
60 | 45 | ->end(); |
|
61 | |||
62 | 45 | $this->_group($node); |
|
63 | 45 | $this->_tags($node); |
|
64 | 45 | $this->_label($node); |
|
65 | |||
66 | 45 | return $node; |
|
67 | } |
||
69 |