Supported Versions: PHP 5 >= 5.2.1, PHP 7, PHP 8
Returns directory path used for temporary files
<?php sys_get_temp_dir(): string
<?php public function test_can_determine_if_roadrunner_server_process_is_running_when_master_is_running()
{
$inspector = new ServerProcessInspector(
$processIdFile = new ServerStateFile(sys_get_temp_dir().'/swoole.pid'),
new SymfonyProcessFactory,
$posix = Mockery::mock(PosixExtension::class)
);
<?php public function test_can_determine_if_roadrunner_server_process_is_running_when_master_cant_be_communicated_with()
{
$inspector = new ServerProcessInspector(
$processIdFile = new ServerStateFile(sys_get_temp_dir().'/swoole.pid'),
new SymfonyProcessFactory,
$posix = Mockery::mock(PosixExtension::class)
);
<?php public function test_roadrunner_server_process_can_be_reloaded()
{
$inspector = new ServerProcessInspector(
$processIdFile = new ServerStateFile(sys_get_temp_dir().'/swoole.pid'),
$processFactory = Mockery::mock(SymfonyProcessFactory::class),
new PosixExtension
);
<?php {
public function test_server_state_file_can_be_managed()
{
$stateFile = new ServerStateFile(sys_get_temp_dir().'/roadrunner.json');
$stateFile->delete();
<?php {
$inspector = new ServerProcessInspector(
$dispatcher = Mockery::mock(SignalDispatcher::class),
$processIdFile = new ServerStateFile(sys_get_temp_dir().'/swoole.pid'),
Mockery::mock(Exec::class),
);
<?php {
$inspector = new ServerProcessInspector(
$dispatcher = Mockery::mock(SignalDispatcher::class),
$processIdFile = new ServerStateFile(sys_get_temp_dir().'/swoole.pid'),
Mockery::mock(Exec::class),
);
<?php {
$inspector = new ServerProcessInspector(
$dispatcher = Mockery::mock(SignalDispatcher::class),
$processIdFile = new ServerStateFile(sys_get_temp_dir().'/swoole.pid'),
Mockery::mock(Exec::class),
);
<?php {
$inspector = new ServerProcessInspector(
$dispatcher = Mockery::mock(SignalDispatcher::class),
$processIdFile = new ServerStateFile(sys_get_temp_dir().'/swoole.pid'),
Mockery::mock(Exec::class),
);
<?php {
$inspector = new ServerProcessInspector(
$dispatcher = Mockery::mock(SignalDispatcher::class),
$processIdFile = new ServerStateFile(sys_get_temp_dir().'/swoole.pid'),
$exec = Mockery::mock(Exec::class),
);
<?php {
public function test_server_state_file_can_be_managed()
{
$stateFile = new ServerStateFile(sys_get_temp_dir().'/swoole.json');
$stateFile->delete();