Open drauggres opened 2 years ago
new SubpPocess("tidevice",["-u",options.serial, "xctest", "-B","com.apple.test.W ebDriverAgentRunner-Runner"])
Can be added to webdriveragentrunner file, also increases speed of ios loading by 10x times
extends ProcessRunner
can be used to implement tidevice similar to ws-qvh.
existing xcuitest driver can be reused with below changes as xcode build is not required
await server.driver.createSession({
platformName: 'iOS',
deviceName: 'my iphone',
udid: this.udid,
wdaLocalPort: this.wdaLocalPort,
usePrebuiltWDA: true,
mjpegServerPort: remoteMjpegServerPort,
webDriverAgentUrl: "http://127.0.0.1:"+this.wdaLocalPort
});
// await server.driver.wda.xcodebuild.waitForStart(new timing.Timer().start());
// if (server.driver?.wda?.xcodebuild?.xcodebuild) {
// server.driver.wda.xcodebuild.xcodebuild.on('exit', (code: number) => {
// this.started = false;
// this.starting = false;
// server.driver.deleteSession();
// delete this.server;
// this.emit('status-change', { status: 'stopped', code });
// if (this.holders > 0) {
// this.start();
// }
// });
// } else {
// this.started = false;
// this.starting = false;
// delete this.server;
// throw new Error('xcodebuild process not found');
// }
Discussed in https://github.com/NetrisTV/ws-scrcpy/discussions/194