Page 1 of 1

Instrumentation Failed

Posted: Wed Jan 09, 2019 5:54 am
by Gowtham
Hi,

> We are trying to install Chrome on Android Emulator. But the instrumentation failed. I have attached the error.
> We tried using Instrumentation Flag as '-static -multidex' also as suggested on the forum. But still we are getting the same error.
> So we tried using different Versions of Chrome,

Ranorex Version - 7.2.1
The Android(Tablet) Version of the Emulator - Android 7.1.1
Chrome APK Versions Tried - Chrome v38.0(API Level 14), v39.0(API Level 14), v40.0(API Level 16), v42.0(API Level 14), v43.0(API Level 16), v45.0(API Level 16), v64.0(API Level 21), v71.0(API Level 16)

> We tried installing the above APKs with no luck.
> Please advice, is this an incompatibility issue? Is the Chrome version not compatible with Android version? If so, kindly let us know which Chrome version and API Level should be used.

Re: Instrumentation Failed

Posted: Wed Jan 09, 2019 8:48 am
by odklizec
Hi,

I'm afraid, without knowing more details about the error you got (available under "Details"), there is not much anyone here can do or suggest.

As you are trying to instrument a 3rd party app, make sure the apk is not obfuscated! This is something most app developers probably do before releasing an app to public!

At next, Ranorex 7.2.1 is too old and no longer supported! Please try the instrumentation in most recent Ranorex 8.3.2 (even in trial mode).

As for the Chrome compatibility with Android version you are using, this is something you must consult with Chrome developers. Have you tried to install Chrome manually (i.e. without instrumenting it)?

Re: Instrumentation Failed

Posted: Wed Jan 09, 2019 10:14 am
by Gowtham
Hi odklizec,

The error as follows,

System.Exception: Failed to deploy the application via USB. Failure [INSTALL_FAILED_NO_MATCHING_ABIS: Failed to extract native libraries, res=-113]

8187 KB/s (32002466 bytes in 3.817s)

at Ranorex.Plugin.Mobile.Tools.Android.AndroidUsbDeploymentService.CheckForErrorsThatDoNotResultInErrorCode(ProcessRunner runner)
at Ranorex.Plugin.Mobile.Tools.Android.AndroidUsbDeploymentService.Deploy(String apkFilePath, String deviceInstance, IToolConfig config)
at Ranorex.Controls.Instrumentation.Workers.AndroidWorker.Deploy(String packageName, String toDeploy)
at Ranorex.Controls.Instrumentation.Workers.AndroidWorker.Run()
at Ranorex.Controls.AndroidInstrumentProgressPage.bgw_DoWork(Object sender, DoWorkEventArgs e)


> Regarding Ranorex Version - We already raised a concern about it. But as of now, Ranorex 7.2.1 is all we got. We have to somehow try to fix this issue on Ranorex 7.2.1 only.
> Regarding Chrome - As we are working with Android Emulators, Chrome version 55 is available on the Emulator. But when we try to record the script on Emulator, the Chrome option is not displayed. That is the reason why we are trying to instrument it through Ranorex.
> The query is simple, we have to test a web application(Record & Playback) on Android Emulator(Different Android Devices) using Ranorex 7.2.1.
> Is it possible? or Are we going in a wrong path?

Re: Instrumentation Failed

Posted: Wed Jan 09, 2019 10:21 am
by odklizec
Hi,

Natively, mobile webs can be tested only via Ranorex-own RxBrowser. If you want to use native Android (Chrome) or iOS (Safari) web browsers, you must use Appium integration. Check for example this video:
https://www.youtube.com/watch?v=SbWb1Y8597Q

Re: Instrumentation Failed

Posted: Fri Jan 11, 2019 6:50 am
by Gowtham
Hi odklizec,

Thanks for helping us out. Your help is much appreciated :)

> We have installed Ranorex 8.3.2 trial version as you suggested.
> We have recorded a script on Chrome on Windows 7. We are trying to run the script on Android Emulator(Chrome Browser v55.0) through Appium.
> When we try to run the script, the Emulator Browser opens with the url whatever we've given and it searches for the element. Eventually it fails to find the element.
> I have attached the screenshot for your reference.
> Initially it was "mouse click" event, but that was not working. So we changed it to "touch". But this is also not working.
> We tried to track the element on the Emulator. But we could not.

Is there anything wrong? Kindly help us.

Re: Instrumentation Failed

Posted: Fri Jan 11, 2019 9:57 am
by odklizec
Hi,

If I understand it right, your original problem is now solved and there is a new issue? Next time, please create a new post, instead of using an old post for new problem ;) Thanks.

As for your new issue, well, I think that switching touch and click is useless as the main problem is, that Ranorex apparently cannot find the element in question. Hence it cannot click or touch it. Unfortunately, I'm not quite sure how to debug this kind of issue on webdriver? While using Desktop/Mobile endpoint, I would suggest to take the snapshot of entire DOM and examine if the xpath you have in repo really exists in the snapshot. But if I'm not mistaken, taking snapshots is not possible on webdriver? I would suggest to try to replace the unique identifier #'menu' in Forms xpath with @id='menu'. At next, try to reduce the xpath to just //div[@id='menu']//span[@innertext='Forms'], eventually just //span[@innertext='Forms'] or //*[@innertext='Forms'].

Re: Instrumentation Failed

Posted: Wed Mar 27, 2019 3:18 pm
by Dhouha
Hi,

I'm using Appium webdriver endpoint to test a mobile web application in the native browser Chrome.
I followed step by step this video : https://www.youtube.com/watch?v=SbWb1Y8597Q (It's so helpfull thank you :) )

After running => the browser is launched with the right url but I have also the same problem that says "Not element found" when trying to click on the button.
I changed the xpath by using @ instead of # and I reduced the xpath as said in the last post, but nothing works

Any other idea please :?: :idea:

Thanks !
Dhouha

Re: Instrumentation Failed

Posted: Fri Mar 29, 2019 1:30 pm
by McTurtle
Hi Dhouha,

Just create a dom element in your repository with no attributes and create a "Snapshot" action in your recording table and run the test via Appium:
dom.png
Your report should then contain a snapshot of the dom from the device. If you compare that snapshot to the snapshot of the browser on your desktop, then they will probably not be the same for whatever reason. Can you try that?

Regards,
McTurtle

Re: Instrumentation Failed

Posted: Wed Sep 04, 2019 1:18 pm
by Dhouha
Hello,

It works now ! Thank you very much :D

Regards.
Dhouha

Re: Instrumentation success / but mobile application stops when recording

Posted: Thu Mar 05, 2020 1:32 pm
by Dhouha
Hello,

Now I'm working on another project in order to automate tests on mobile android application.
The instrumentation and deployement are well done, but when I try to record I select my endpoint and the application to test, and this message is displayed ==> "Unfortunaly "app name" has stopped"
I don't know why !! I m using the last version of ranorex 9 and his renaorex service app.
I tried with another mobile application and it works !

Any idea please ??

Regards
Dhouha

Re: Instrumentation Failed

Posted: Thu Mar 05, 2020 1:37 pm
by odklizec
Hi,

I think this kind of issue will require Ranorex investigation? So all I can suggest is to create a support ticket:
https://www.ranorex.com/support-query/