1 | <?php |
||
20 | class ProphecyMockingStrategy extends AbstractMockingStrategy |
||
21 | { |
||
22 | private const CLASS_NAME = Prophet::class; |
||
23 | private const PACKAGE_NAME = 'phpspec/prophecy'; |
||
24 | |||
25 | /** |
||
26 | * @var Prophet |
||
27 | */ |
||
28 | private $prophet; |
||
29 | |||
30 | /** |
||
31 | * PHPUnitMockingStrategy constructor. |
||
32 | * |
||
33 | * @throws MissingDependencyException |
||
34 | */ |
||
35 | 2 | public function __construct() |
|
42 | |||
43 | /** |
||
44 | * @param string $fqcn |
||
45 | * @return ObjectProphecy |
||
46 | */ |
||
47 | 22 | protected function doBuild(string $fqcn): ObjectProphecy |
|
51 | |||
52 | /** |
||
53 | * @param ObjectProphecy $mock |
||
54 | * @param MethodStub $stub |
||
55 | * @return void |
||
56 | */ |
||
57 | 20 | protected function doDecorateWithMethod($mock, MethodStub $stub): void |
|
68 | |||
69 | /** |
||
70 | * @param ObjectProphecy $mock |
||
71 | * @return mixed |
||
72 | * |
||
73 | * @throws MockNotCreatedException |
||
74 | */ |
||
75 | 16 | protected function doGet($mock) |
|
88 | |||
89 | /** |
||
90 | * @param ObjectProphecy $mock |
||
91 | * @param string $methodName |
||
92 | * @return object |
||
93 | */ |
||
94 | 2 | protected function doCall($mock, string $methodName) |
|
98 | } |
||
99 |