Completed
Pull Request — master (#8)
by Jeremy
04:54
created

MissingMethod::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 5
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 7
ccs 5
cts 5
cp 1
rs 9.4285
cc 1
eloc 4
nc 1
nop 2
crap 1
1
<?php
2
3
4
namespace Scientist\SideEffects;
5
6
7
class MissingMethod extends \RuntimeException
8
{
9
    /**
10
     * MissingMethod constructor.
11
     * @param mixed $instance
12
     * @param string $method
13
     */
14 1
    public function __construct($instance, $method)
15
    {
16 1
        parent::__construct(sprintf("%s does not implement method %s",
17 1
            get_class($instance),
18
            $method
19 1
        ));
20
    }
21
}