1 | <?php |
||
26 | class PhiremockProcess |
||
27 | { |
||
28 | /** |
||
29 | * Phiremock server log. |
||
30 | * |
||
31 | * @var string |
||
32 | */ |
||
33 | const LOG_FILE_NAME = 'phiremock.log'; |
||
34 | |||
35 | /** |
||
36 | * @var \Symfony\Component\Process\Process |
||
37 | */ |
||
38 | private $process; |
||
39 | |||
40 | /** |
||
41 | * Starts Phiremock. |
||
42 | * |
||
43 | * @param string $ip |
||
44 | * @param int $port |
||
45 | * @param string $path |
||
46 | * @param string $logsPath |
||
47 | * @param bool $debug |
||
48 | * @param mixed $expectationsPath |
||
49 | */ |
||
50 | public function start($ip, $port, $path, $logsPath, $debug, $expectationsPath) |
||
62 | |||
63 | /** |
||
64 | * Stops the process. |
||
65 | */ |
||
66 | public function stop() |
||
70 | |||
71 | /** |
||
72 | * @param string $ip |
||
73 | * @param int $port |
||
74 | * @param bool $debug |
||
75 | * @param string $expectationsPath |
||
76 | * @param string $phiremockPath |
||
77 | */ |
||
78 | private function initProcess($ip, $port, $debug, $expectationsPath, $phiremockPath) |
||
98 | |||
99 | /** |
||
100 | * @param bool $debug |
||
101 | */ |
||
102 | private function logPhiremockCommand($debug) |
||
108 | } |
||
109 |