DriverService
in package
Start local WebDriver service (when remote WebDriver server is not used).
This will start new process of respective browser driver and take care of its lifecycle.
Table of Contents
Properties
- $args : array<string|int, mixed>
- $environment : array<string|int, mixed>
- $executable : string
- $process : Process|null
- $url : string
Methods
- __construct() : mixed
- getURL() : string
- isRunning() : bool
- start() : DriverService
- stop() : DriverService
- checkExecutable() : string
- checkWasStarted() : mixed
- setExecutable() : mixed
- createProcess() : Process
- isExecutable() : bool
- Check whether given file is executable directly or using system PATH
Properties
$args
private
array<string|int, mixed>
$args
$environment
private
array<string|int, mixed>
$environment
$executable
private
string
$executable
$process
private
Process|null
$process
$url
private
string
$url
Methods
__construct()
public
__construct(string $executable, int $port[, array<string|int, mixed> $args = [] ][, array<string|int, mixed>|null $environment = null ]) : mixed
Parameters
- $executable : string
- $port : int
-
The given port the service should use.
- $args : array<string|int, mixed> = []
- $environment : array<string|int, mixed>|null = null
-
Use the system environment if it is null
getURL()
public
getURL() : string
Return values
stringisRunning()
public
isRunning() : bool
Return values
boolstart()
public
start() : DriverService
Return values
DriverServicestop()
public
stop() : DriverService
Return values
DriverServicecheckExecutable()
protected
static checkExecutable(string $executable) : string
Parameters
- $executable : string
Tags
Return values
stringcheckWasStarted()
protected
checkWasStarted(Process $process) : mixed
Parameters
- $process : Process
setExecutable()
protected
setExecutable(string $executable) : mixed
Parameters
- $executable : string
Tags
createProcess()
private
createProcess() : Process
Return values
ProcessisExecutable()
Check whether given file is executable directly or using system PATH
private
isExecutable(string $filename) : bool
Parameters
- $filename : string