Total Complexity | 2 |
Total Lines | 21 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php namespace Chekote\Phake\Stubber\Answers; |
||
9 | class UnMockedResponseExceptionAnswer implements Phake_Stubber_IAnswer |
||
10 | { |
||
11 | /** |
||
12 | * {@inheritdoc} |
||
13 | */ |
||
14 | public function getAnswerCallback($context, $method) |
||
15 | { |
||
16 | $class = get_parent_class($context); |
||
17 | |||
18 | return function () use ($class, $method) { |
||
19 | throw new UnMockedResponseException( |
||
20 | "$class::$method was called on mock without having its response mocked" |
||
21 | ); |
||
22 | }; |
||
23 | } |
||
24 | |||
25 | /** |
||
26 | * {@inheritdoc} |
||
27 | */ |
||
28 | public function processAnswer($answer) |
||
30 | } |
||
31 | } |
||
32 |