You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The error is caused because the createAppiumDriver() function calls to AppiumDriver.applyAdditionalSettings(args) which expects having an args.device argument, which is not present and it raises the Cannot read property 'token' of undefined.
But after that, the createAppliumDriver() function defines the args.device, so the sequence is:
public static async createAppiumDriver(port: number, args: INsCapabilities) {
...
if (!args.attachToDebug && !args.sessionId) {
await AppiumDriver.applyAdditionalSettings(args); // --> raises the error
}
...
prepareApp(args);
if (!args.device) {
if (args.isAndroid) {
// --> but here we set the device (why later?)
args.device = DeviceManager.getDefaultDevice(...);
} else {
args.device = DeviceManager.getDefaultDevice(args);
}
}
}
The text was updated successfully, but these errors were encountered:
msaelices
added a commit
to nativescript-vue/nativescript-vue-ui-tests
that referenced
this issue
Aug 1, 2018
Hey @msaelices, indeed you are right and I have totally missed this scenario, basically we use another approach to do that where appium capabilites is provided like that: ./node_modules/.bin/mocha --opts mocha.opts --runType android24.sauce --sauceLab --appPath nativescript-ui-sidedrawer-demo-angular-release.apk
Anyway I will try to fix the issue in the next few days and release a new version of the plugin.
Which platform(s) does your issue occur on?
Please, provide the following version numbers that your issue occurs with:
Please, tell us how to recreate the issue in as much detail as possible.
Please reproduce the code below.
Is there any code involved?
Sample code:
Sample capabilities
appium.capabilities.json
file:The error is caused because the
createAppiumDriver()
function calls toAppiumDriver.applyAdditionalSettings(args)
which expects having anargs.device
argument, which is not present and it raises theCannot read property 'token' of undefined
.But after that, the
createAppliumDriver()
function defines theargs.device
, so the sequence is:The text was updated successfully, but these errors were encountered: