Android Object Testing - On-Screen Action "Drag..." option doesn't recognize objects anymore
Hi,
I started Android application tests in TestComplete. I was struggling with devices and application preparation to start with object test. I did everything the same like here it was written: https://support.smartbear.com/testcomplete/docs/app-testing/mobile/android/preparing/index.html
- Computer recognizes my device (Android 10 - Huawei Mate 20 Lite)
- I got enable TestComplete Android Agent on this device
- Testcomplete saying that application which I trying to test is already instrumented
- After I click on "Show Mobile Screen", I see my device and my app on it.
I tried to use "On-Screen Action" opperation with "Drag the target.." few times unsuccessfully. After this I clicked "Point and fix" option and I pressed (Ctrl+Shift+A) - that was a moment when I finally saw objects from application in those red rectangles. I prepared few actions on this app and next to it I run test (I had on my "actions queue" firstly "Run TestedApp" and below this, only "On-screen actions"). Application re-installed and test failed. I tried one more time do "On-Screen action" where i select objects, but since then I can't find out how to select objects instead of whole application screen when I use "On-screen action".
Please help.
Adam
I got answer from support:
"Our developers determined why the issue occurs - your app uses the controls which are not supported (androidx), and when TestComplete instruments such an app, it doesn't take into account the code which these controls add. Thus, we will need to make quite complex changes to the instrumentation process, this could take significant time - currently, we don't have any ETA when or whether we support such type of Android apps."
They recomended anyway to instument my application by PatchServices.jar from source code:
https://support.smartbear.com/testcomplete/docs/app-testing/mobile/android/preparing/instrumenting-apps/ide/android-studio.htmlMy developers added this .lib and it finally starts recognize my objects in app :).
So if your application uses "androidx" controls, instrumentation in TestComplete will be not enough, you will need do this by adding PatchServices.lib in source code.
Kind regards,
Adam Ryś