Conditions | 1 |
Paths | 1 |
Total Lines | 16 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php declare(strict_types = 1); |
||
21 | public static function startWebserver(): void |
||
22 | { |
||
23 | /** @noinspection PhpUndefinedConstantInspection */ |
||
24 | $command = sprintf( |
||
25 | 'php -S %s:%d -t %s %s', |
||
26 | PHP_WEBSERVER_HOST, |
||
27 | (int) PHP_WEBSERVER_PORT, |
||
28 | self::$webserverDocroot, |
||
29 | self::$webserverRouter |
||
30 | ); |
||
31 | |||
32 | self::$webserverProcess = new Process($command); |
||
33 | |||
34 | self::$webserverProcess->start(); |
||
35 | |||
36 | self::verifyProcessRunning(self::$webserverProcess); |
||
37 | } |
||
58 |