Skip to content

Commit c847536

Browse files
committed
fix(device-controller): token in server scenario
1 parent ad152bd commit c847536

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: lib/device-controller.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ export class DeviceManger implements IDeviceManager {
3232
if (process.env["DEVICE_TOKEN"]) {
3333
device.token = process.env["DEVICE_TOKEN"];
3434
const allDevices = await DeviceController.getDevices({ platform: args.appiumCaps.platformName });
35-
const foundDevice = DeviceController.filter(allDevices, { token: device.token })[0];
35+
const foundDevice = DeviceController.filter(allDevices, { token: device.token.replace("emulator-", "") })[0];
3636
console.log("Device: ", foundDevice);
3737
return foundDevice;
3838
}

0 commit comments

Comments
 (0)