mirror of
https://github.com/priyanshujain/sanderling.git
synced 2026-10-02 19:17:10 +00:00
fix(sidecar): pick free WDA port instead of hardcoded 9100
Use SocketUtils.nextFreePort to pick a free port in the 22000-23000 range rather than hardcoding 9100, which only worked if a previous WDA session left a listener there.
This commit is contained in:
1 parent
a70c865afa
commit
73dc7948ab
1 file changed
+2
-1
@@ -492,11 +492,12 @@ class IosDriverBackend(private val udid: String) : DriverBackend {
|
||||
init {
|
||||
val httpClient = xcuitest.api.OkHttpClientInstance.get()
|
||||
val metrics = maestro.utils.NoOpMetrics()
|
||||
val wdaPort = maestro.utils.SocketUtils.nextFreePort(22000, 23000)
|
||||
val installer = xcuitest.installer.LocalXCTestInstaller(
|
||||
udid,
|
||||
"localhost",
|
||||
false,
|
||||
9100,
|
||||
wdaPort,
|
||||
metrics,
|
||||
httpClient,
|
||||
false,
|
||||
|
||||
Reference in new issue
Block a user