Conditions | 4 |
Paths | 6 |
Total Lines | 14 |
Code Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Tests | 10 |
CRAP Score | 4 |
Changes | 0 |
1 | <?php |
||
35 | 3 | public function process(array $path): void |
|
36 | { |
||
37 | 3 | $exception = null; |
|
38 | 3 | $files = $this->listFiles($path); |
|
39 | 3 | sort($files); |
|
40 | 3 | foreach ($files as $file) { |
|
41 | try { |
||
42 | 2 | require_once $file; |
|
43 | 1 | } catch (AfterloadException $ex) { |
|
44 | 1 | $exception = $ex->addPrev($exception); |
|
45 | } |
||
46 | } |
||
47 | 3 | if (!empty($exception)) { |
|
48 | 1 | throw $exception; |
|
49 | } |
||
77 |