Passed
Push — main ( 03d0aa...06b87c )
by Stanislav
02:17
created

CircularDependencyException   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 9
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
eloc 5
dl 0
loc 9
ccs 5
cts 5
cp 1
rs 10
c 0
b 0
f 0
wmc 2

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 7 2
1
<?php declare(strict_types=1);
2
3
namespace Diezz\YamlToObjectMapper\Resolver;
4
5
use RuntimeException;
6
7
class CircularDependencyException extends RuntimeException
8
{
9 2
    public function __construct(array $path)
10
    {
11 2
        $message = 'Circular dependency detected at path: ';
12 2
        foreach ($path as $item) {
13 2
            $message .= "$item->";
14
        }
15 2
        parent::__construct(substr($message, 0, -2));
16 2
    }
17
}
18