Some times Ranorex can't click on the android permission dialog.
this how i find it
P.S. Android OS automation = True
please tell us how to do it
Some times Ranorex can't click on the permission dialog
Re: Some times Ranorex can't click on the permission dialog
I don't believe this particular dialog can be automated, even with Android OS Automation = true. It is a security feature of Android to keep nefarious apps from automating the process of giving permissions to the phone.
Shortcuts usually aren't...
Re: Some times Ranorex can't click on the permission dialog
when we are testing we have to install the app. after doing it prompts this. isn't there any workaround even ?
Re: Some times Ranorex can't click on the permission dialog
I use ADB commands to interact with this pop up. A USB connection would be required.
For example, if you want to click "Allow" you must preform a down, right and then a center command.
You would do something like the following:
*** Shout out to Kendall from Ranorex support for giving me this info. ***
For example, if you want to click "Allow" you must preform a down, right and then a center command.
You would do something like the following:
- adb.exe -s ADB_DEVICE_NAME shell input keyevent KEYCODE_DPAD_DOWN
- adb.exe -s ADB_DEVICE_NAME shell input keyevent KEYCODE_DPAD_RIGHT
- adb.exe -s ADB_DEVICE_NAME shell input keyevent KEYCODE_DPAD_CENTER
*** Shout out to Kendall from Ranorex support for giving me this info. ***
Re: Some times Ranorex can't click on the permission dialog
Yes, i'm also using following adb commands for permission
but unfortunately for android.permission.CALL_PHONE i get following error, that's why I had to use Ranorex.
Problem i'm having is few times clicking is success and most of the time it fails in automated environment. For localbox testing it is other way round.
Code: Select all
adb shell pm grant pnl.order.dev android.permission.ACCESS_FINE_LOCATION
adb shell pm grant pnl.order.dev android.permission.WRITE_EXTERNAL_STORAGE
adb shell pm grant pnl.order.dev android.permission.CAMERA
adb shell pm grant pnl.order.dev android.permission.CALL_PHONE
Code: Select all
Operation not allowed: java.lang.SecurityException: Package pnl.order.dev has not requested permission android.permission.CALL_PHONE
Re: Some times Ranorex can't click on the permission dialog
I added
permission to AndroidManifest.xml file, and it solved that exception throwing when grant command.
Code: Select all
<uses-permission android:name="android.permission.CALL_PHONE"/>