xcuitrunner 未启动-SocketException

xcuitrunner 未启动-SocketException

我尝试在 Windows 机器上启动 xcuitrunner,但出现以下异常:

Unhandled Exception: System.Net.Internals.SocketExceptionFactory+ExtendedSocketException: No connection could be made because the target machine actively refused it: [::ffff:127.0.0.1]:27015
  at System.Net.Sockets.Socket.DoConnect(EndPoint endPointSnapShot, SocketAddress socketAddress)
  at System.Net.Sockets.Socket.Connect(EndPoint remoteEP)
  at System.Net.SOckets.Socket.Connect(IPAddress[] addresses, Int32 port)
--- End of stack trace from previous location where exception was thrown ---
  at System.Net.Sockets.Socket.Connect(IPAddress[] addresses, Int32 port)
  at System.Net.Sockets.Socket.Connect(String host, Int32 port)
  at Quamotion.Devices.iOS.Managed.MuxerDeviceClient.Connect(Boolean forceTcp, String muxerHost, Int32 muxerPort)
  at Quamotion.Devices.iOS.Managed.MuxerDeviceClient.ListDevices(CancellationToken cancellationToken)
  at XcuitRunner.Program.<>c__DisplayClass5_1.<Main>b__2()
  at Microsoft.Extension.CommandLineUtils.CommandLineApplication.Execute(String[] args)
  at XcuitRunner.Program.Main(String[] args)

当我通过检查与端口 27015 关联的进程时netstat,我发现不存在任何进程。

看起来 xcuitrunner 仍在寻找端口 27015。

我该如何解决这个问题?

答案1

端口 27015 是 Apple Mobile Device Service 使用的端口。此服务管理与 iOS 设备的连接。您可以通过安装 iTunes 来安装 Apple Mobile Device Service。

您能否检查 iTunes 是否已安装,并且 Apple Mobile Device Service 是否正在运行?

相关内容