@@ -38,21 +38,23 @@ class Config
3838 public const DEFAULT_SUITES = [];
3939 public const DEFAULT_WAIT_UNTIL_READY = false ;
4040 public const DEFAULT_WAIT_UNTIL_READY_TIMEOUT = 30 ;
41+ public const DEFAULT_WAIT_UNTIL_READY_INTERVAL_MICROS = 50000 ;
4142
4243 public const DEFAULT_CONFIG = [
43- 'listen ' => self ::DEFAULT_INTERFACE . ': ' . self ::DEFAULT_PORT ,
44- 'debug ' => self ::DEFAULT_DEBUG_MODE ,
45- 'start_delay ' => self ::DEFAULT_DELAY ,
46- 'bin_path ' => self ::DEFAULT_PHIREMOCK_PATH ,
47- 'expectations_path ' => self ::DEFAULT_EXPECTATIONS_PATH ,
48- 'server_factory ' => self ::DEFAULT_SERVER_FACTORY ,
49- 'certificate ' => self ::DEFAULT_CERTIFICATE ,
50- 'certificate_key ' => self ::DEFAULT_CERTIFICATE_KEY ,
51- 'cert_passphrase ' => self ::DEFAULT_CERTIFICATE_PASSPHRASE ,
52- 'extra_instances ' => self ::DEFAULT_EXTRA_INSTANCES ,
53- 'suites ' => self ::DEFAULT_SUITES ,
54- 'wait_until_ready ' => self ::DEFAULT_WAIT_UNTIL_READY ,
55- 'wait_until_ready_timeout ' => self ::DEFAULT_WAIT_UNTIL_READY_TIMEOUT
44+ 'listen ' => self ::DEFAULT_INTERFACE . ': ' . self ::DEFAULT_PORT ,
45+ 'debug ' => self ::DEFAULT_DEBUG_MODE ,
46+ 'start_delay ' => self ::DEFAULT_DELAY ,
47+ 'bin_path ' => self ::DEFAULT_PHIREMOCK_PATH ,
48+ 'expectations_path ' => self ::DEFAULT_EXPECTATIONS_PATH ,
49+ 'server_factory ' => self ::DEFAULT_SERVER_FACTORY ,
50+ 'certificate ' => self ::DEFAULT_CERTIFICATE ,
51+ 'certificate_key ' => self ::DEFAULT_CERTIFICATE_KEY ,
52+ 'cert_passphrase ' => self ::DEFAULT_CERTIFICATE_PASSPHRASE ,
53+ 'extra_instances ' => self ::DEFAULT_EXTRA_INSTANCES ,
54+ 'suites ' => self ::DEFAULT_SUITES ,
55+ 'wait_until_ready ' => self ::DEFAULT_WAIT_UNTIL_READY ,
56+ 'wait_until_ready_timeout ' => self ::DEFAULT_WAIT_UNTIL_READY_TIMEOUT ,
57+ 'wait_until_ready_interval ' => self ::DEFAULT_WAIT_UNTIL_READY_INTERVAL_MICROS ,
5658 ];
5759
5860 /** @var string */
@@ -87,6 +89,8 @@ class Config
8789 private $ waitUntilReady ;
8890 /** @var int */
8991 private $ waitUntilReadyTimeout ;
92+ /** @var int */
93+ private $ waitUntilReadyCheckIntervalMicros ;
9094
9195 /** @throws ConfigurationException */
9296 public function __construct (array $ config , callable $ output )
@@ -106,6 +110,7 @@ public function __construct(array $config, callable $output)
106110 $ this ->suites = $ config ['suites ' ];
107111 $ this ->waitUntilReady = (bool ) $ config ['wait_until_ready ' ];
108112 $ this ->waitUntilReadyTimeout = (int ) $ config ['wait_until_ready_timeout ' ];
113+ $ this ->waitUntilReadyCheckIntervalMicros = (int ) $ config ['wait_until_ready_interval ' ];
109114 }
110115
111116 public function getSuites (): array
@@ -184,7 +189,7 @@ public function isSecure(): bool
184189 && $ this ->getCertificateKeyPath () !== null ;
185190 }
186191
187- public function isWaitUntilReady (): bool
192+ public function waitUntilReady (): bool
188193 {
189194 return $ this ->waitUntilReady ;
190195 }
@@ -194,6 +199,11 @@ public function getWaitUntilReadyTimeout(): int
194199 return $ this ->waitUntilReadyTimeout ;
195200 }
196201
202+ public function getWaitUntilReadyIntervalMicros (): int
203+ {
204+ return $ this ->waitUntilReadyCheckIntervalMicros ;
205+ }
206+
197207 /** @throws ConfigurationException */
198208 public static function getDefaultLogsPath (): string
199209 {
0 commit comments