Completed
Pull Request — master (#8)
by Jeremy
06:38 queued 04:13
created

MissingProperty   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 100%

Importance

Changes 2
Bugs 1 Features 1
Metric Value
wmc 1
c 2
b 1
f 1
lcom 0
cbo 0
dl 0
loc 16
ccs 6
cts 6
cp 1
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 8 1
1
<?php
2
3
4
namespace Scientist\SideEffects;
5
6
class MissingProperty extends \RuntimeException
7
{
8
    /**
9
     * MissingProperty constructor.
10
     * @param string $instance
11
     * @param string $property
12
     */
13 2
    public function __construct($instance, $property)
14
    {
15 2
        parent::__construct(sprintf(
16 2
            "%s does not implement property %s",
17 2
            get_class($instance),
18
            $property
19 2
        ));
20 2
    }
21
}
22