This repository was archived by the owner on Jul 29, 2024. It is now read-only.
This repository was archived by the owner on Jul 29, 2024. It is now read-only.
Options and fixes for executing tests on mobile devices via BrowserStack #2198
Closed
Description
Test automation on Android and Apple mobile devices via BrowserStack is failing (also with Sauce Lab), and this seems to be about the drivers they use. I have made experiments to determine the why and how to bypass them.
For both Android and Apple:
- executing async script is not working, while waiting for a sync script is working. This way, client side scripts calling a callback have to simply return. Apple is simply not responding, Android is telling: "This is feature will be implemented soon"
For Android:
- client side scripts have to be one line (and line comments - comment blocks are ok)
- client side scripts arguments cannot be null, and that is the case in at least one of them (error message when an argument is null: "Javascript arguments can be a Number, a Boolean, a String, a WebElement, or a List or a Map of those. Got: null")
- only javascript locators seem to work properly without saying the locator is invalid
- slowness is forcing us to add waiting times
So the issue is about implementing options for prefering sync scripts with wait calls, avoiding null arguments, using javascript locators instead of driver ones, adding default wait time for each command for slow devices, and, adding an option toggling them all to finally enable testing remotely on mobile devices with protractor !