Adding new devices to RobusTest - Android
When adding a new Andorid device to the RobusTest platform for the first time, you need to first prepare the device by performing the following set of actions on it:
Turn on Developer Mode
Go to the ‘About Phone’ section under Settings on your mobile device
Now, tap on the build number field 7 times continuously to turn on ‘Developer Options’
Stay Awake should be turned on
USB Debugging should be turned on
Allow mock locations
Set USB connection behavior to act as media device
Set location as only GPS (option may be “only device” on some devices)
Remove any lock screen
Security settings - Allow installation from unknown sources
Set as true “Do not verify apps installed over USB”
Display - Set rotation as off
Display - Set screen timeout to Never (in case Never is not an option set it to maximum possible time available)
12. Once the above steps are completed, plug the device into the node server through a USB cable. Make sure you use a good quality cable for better data transfer, reliable connectivity and better device charging.
Upon connecting the device, an alert message with the title “Allow USB Debugging?” should show up on the device screen. Select the checkbox to “Always allow from this computer”. Tap on OK on the device
Once the device is plugged in, the system will take upto 2 minutes to identify the device and add it to devices list.
Confirm that you are able to view the device in your device list from manual and automation testing.
Additional Steps for Xiaomi or MI devices:
Instructions for Mi/Xiaomi devices
1.Security App
Tap on the Security App
Tap on the Permissions Icon
Tap on the Settings icon on the top right
Make sure Install via USB is TURNED OFF
For new device models:
Tap on the Security App
Tap on the Settings icon on the top right
Tap on ‘Security Scan’
Disable ‘Scan before installing’
Disable ‘Auto-updates’
Disable ‘System Updates’
2. Developer Settings
Tap on Settings
Tap on Additional Settings
Tap on Developer Options
Developer Options - TURN ON
USB Debugging - TURN ON
Install via USB - TURN ON
USB Debugging (Security Settings) - TURN ON
Verify apps over USB - Turn OFF
Turn on MIUI Optimization - TURN OFF
3. Privacy
Tap on Settings
Tap on Additional Settings
Tap on Privacy
Unknown Sources - TURN ON
P.S. Some older MI devices may have only one of the above options (i.e., i and ii) available and/or may be named differently. Enable the relevant option
Additional Steps for RealMe devices:
In ‘Developer Options’, enable the setting ‘Disable Permission Monitoring’
Additional Steps for Vivo devices:
Go to ‘Settings’ -> ‘Battery’ -> ‘High Background Power Consumption’
To the ‘Allow’ list, add io.appium.uiautomator2.server
Caveats:
On Samsung device models, you might encounter a pop-up mwindow with the message - “Attention - The connected device is unable to access data on this device. Reconnect the USB cable and try again”.
This is a known issue in Samsung models.
You can try one or more of the following solutions to resolve this:
Disconnected and reconnect the USB cable.
Install ‘Android File Transefer’ or ‘Samsung Smart Switch’ applications on your Mac machine.
Reboot the device and reboot the server to which your device is connected.
Update your device Android OS software.
Note: The above solutions do not guarantee that the window does not come up again.
Devices running on older Andorid versions tend to be slower in response.