@@ -68,7 +68,7 @@ discard block |
||
68 | 68 | ->defaultValue(sys_get_temp_dir() . '/behat-code-coverage-cache') |
69 | 69 | ->end() |
70 | 70 | ->booleanNode('branchAndPathCoverage') |
71 | - ->defaultNull() // use null to mean auto |
|
71 | + ->defaultNull() // use null to mean auto |
|
72 | 72 | ->end() |
73 | 73 | ->arrayNode('filter') |
74 | 74 | ->addDefaultsIfNotSet() |
@@ -83,17 +83,17 @@ discard block |
||
83 | 83 | ->addDefaultsIfNotSet() |
84 | 84 | ->children() |
85 | 85 | ->arrayNode('directories') |
86 | - ->useAttributeAsKey('name') |
|
87 | - ->normalizeKeys(false) |
|
88 | - ->prototype('array') |
|
89 | - ->children() |
|
90 | - ->scalarNode('prefix')->defaultValue('')->end() |
|
91 | - ->scalarNode('suffix')->defaultValue('.php')->end() |
|
92 | - ->end() |
|
93 | - ->end() |
|
86 | + ->useAttributeAsKey('name') |
|
87 | + ->normalizeKeys(false) |
|
88 | + ->prototype('array') |
|
89 | + ->children() |
|
90 | + ->scalarNode('prefix')->defaultValue('')->end() |
|
91 | + ->scalarNode('suffix')->defaultValue('.php')->end() |
|
92 | + ->end() |
|
93 | + ->end() |
|
94 | 94 | ->end() |
95 | 95 | ->arrayNode('files') |
96 | - ->prototype('scalar')->end() |
|
96 | + ->prototype('scalar')->end() |
|
97 | 97 | ->end() |
98 | 98 | ->end() |
99 | 99 | ->end() |
@@ -101,17 +101,17 @@ discard block |
||
101 | 101 | ->addDefaultsIfNotSet() |
102 | 102 | ->children() |
103 | 103 | ->arrayNode('directories') |
104 | - ->useAttributeAsKey('name') |
|
105 | - ->normalizeKeys(false) |
|
106 | - ->prototype('array') |
|
107 | - ->children() |
|
108 | - ->scalarNode('prefix')->defaultValue('')->end() |
|
109 | - ->scalarNode('suffix')->defaultValue('.php')->end() |
|
110 | - ->end() |
|
111 | - ->end() |
|
104 | + ->useAttributeAsKey('name') |
|
105 | + ->normalizeKeys(false) |
|
106 | + ->prototype('array') |
|
107 | + ->children() |
|
108 | + ->scalarNode('prefix')->defaultValue('')->end() |
|
109 | + ->scalarNode('suffix')->defaultValue('.php')->end() |
|
110 | + ->end() |
|
111 | + ->end() |
|
112 | 112 | ->end() |
113 | 113 | ->arrayNode('files') |
114 | - ->prototype('scalar')->end() |
|
114 | + ->prototype('scalar')->end() |
|
115 | 115 | ->end() |
116 | 116 | ->end() |
117 | 117 | ->end() |
@@ -199,7 +199,7 @@ discard block |
||
199 | 199 | $filterDefinition = $container->getDefinition(Filter::class); |
200 | 200 | $codeCoverageDefinition->setFactory([new Reference(self::class), 'initCodeCoverage']); |
201 | 201 | $codeCoverageDefinition->setArguments([$filterDefinition, $filterConfig, $branchPathConfig, $cacheDir, $output]); |
202 | - } catch (NoCodeCoverageDriverAvailableException|Xdebug2NotEnabledException|Xdebug3NotEnabledException $e) { |
|
202 | + } catch (NoCodeCoverageDriverAvailableException | Xdebug2NotEnabledException | Xdebug3NotEnabledException $e) { |
|
203 | 203 | $output->writeln("<comment>No code coverage driver is available. {$e->getMessage()}</comment>"); |
204 | 204 | $canCollectCodeCoverage = false; |
205 | 205 | } |
@@ -212,19 +212,19 @@ discard block |
||
212 | 212 | public function initCodeCoverage(Filter $filter, array $filterConfig, ?bool $branchPathConfig, string $cacheDir, OutputInterface $output): CodeCoverage |
213 | 213 | { |
214 | 214 | // set up filter |
215 | - array_walk($filterConfig['include']['directories'], static function (array $dir, string $path, Filter $filter): void { |
|
215 | + array_walk($filterConfig['include']['directories'], static function(array $dir, string $path, Filter $filter): void { |
|
216 | 216 | $filter->includeDirectory($path, $dir['suffix'], $dir['prefix']); |
217 | 217 | }, $filter); |
218 | 218 | |
219 | - array_walk($filterConfig['include']['files'], static function (string $file, string $key, Filter $filter): void { |
|
219 | + array_walk($filterConfig['include']['files'], static function(string $file, string $key, Filter $filter): void { |
|
220 | 220 | $filter->includeFile($file); |
221 | 221 | }, $filter); |
222 | 222 | |
223 | - array_walk($filterConfig['exclude']['directories'], static function (array $dir, string $path, Filter $filter): void { |
|
223 | + array_walk($filterConfig['exclude']['directories'], static function(array $dir, string $path, Filter $filter): void { |
|
224 | 224 | $filter->excludeDirectory($path, $dir['suffix'], $dir['prefix']); |
225 | 225 | }, $filter); |
226 | 226 | |
227 | - array_walk($filterConfig['exclude']['files'], static function (string $file, string $key, Filter $filter): void { |
|
227 | + array_walk($filterConfig['exclude']['files'], static function(string $file, string $key, Filter $filter): void { |
|
228 | 228 | $filter->excludeFile($file); |
229 | 229 | }, $filter); |
230 | 230 |