Instrumentation success but could not start app

Mobile Testing, Android App Testing.
ostap
Posts: 7
Joined: Fri Aug 31, 2012 12:37 pm

Instrumentation success but could not start app

Post by ostap » Fri Aug 31, 2012 5:01 pm

Hello,

I have instrumented app, but error occurs when I am starting app in the studio, it says : "Cannot enable/disable event synchronization...",
I am trying to perform Instrumentation manually but can not find Ranorex.jar
You have stated that:
You can find the Ranorex.jar file in your Ranorex installation directory:
<Ranorex install dir>\bin\RxEnv\Android\Ranorex.jar
http://www.ranorex.com/support/user-gui ... -code.html

I see only RanorexAutomation.jar, tried to link lib but it does not help.
com.ranorex.android.RanorexAndroidAutomation.Hook(this);
is marked as error because package/object is not present

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: Instrumentation success but could not start app

Post by Support Team » Mon Sep 03, 2012 9:18 am

Hello,

There were some bugs fixed in our new release, which can cause this error.
Please try to update Ranorex to the version 3.3.2 and try it again. If this will not help please send your APK to [email protected].

Regards,
Bernhard
Ranorex Support Team
.
Image

ostap
Posts: 7
Joined: Fri Aug 31, 2012 12:37 pm

Re: Instrumentation success but could not start app

Post by ostap » Mon Sep 03, 2012 2:57 pm

Thanks for reply,

I have installed 3.3.2 and updated Ranorex service on the device.
Now Ranorex.jar is present and code is built OK.

But the same error occurs in Auto instrumentation mode "Cannot enable/disable event synchronization...",
In Manual instrumentation mode apk is created and uploaded but application crashes on device.
Tested on two different apk apps.

I have attached apk files and logs, please take a look, sent to [email protected]

Thanks,
Ostap

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: Instrumentation success but could not start app

Post by Support Team » Tue Sep 04, 2012 10:21 am

Hello Ostap,

Thank you for APK files and the trace logs. We tried to instrument the APK's you sent us and in our case it worked without an error.
Which Android version do you use?
Please make sure that the Ranorex service is installed and running on your device.

Regards,
Bernhard
Ranorex Support Team
.
Image

ostap
Posts: 7
Joined: Fri Aug 31, 2012 12:37 pm

Re: Instrumentation success but could not start app

Post by ostap » Tue Sep 04, 2012 1:08 pm

Hello,

I have used Android version 2.3.3 via Emulator (enabled port forwarding to 31000)

Android service is updated to version 3.3.2, Ranorex studio knows about device, it is added OK, also app is instrumented without any errors. After that app is deployed and installed on device via Ranorex studio.
In case when we press "Start" button on "Recording dialog"
the message appears: "Cannot enable/disable event synchronization because no valid app is running on device".

I am using trial version, may it have some limitations ?

Thanks,
Ostap

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: Instrumentation success but could not start app

Post by Support Team » Wed Sep 05, 2012 2:56 pm

Hello Ostap,

Unfortunately we cannot reproduce the error. In the following section I describe the steps we have done.

Before we started we made sure that:
  • The Ranorex service is installed and running
  • The App is instrumented and installed
  • The Application list shows the instrumented app
  • Ranorex Studio is closed
  • Emulator is closed
  • All other android development tools like eclipse are closed. (eclipse can sometimes interfere with adb connections)
What we have done after that:
  • To make sure to reset all custom adb settings type “adb kill-server” in command prompt
  • Start emulator
  • Unlock emulator screen
  • Start Ranorex studio
  • Check if your device is connected and says „(No app running)“
  • Press “Record”
  • Check “Mobile Recording”
  • Select emulator as device
  • Select app from the app list
  • Press “Start”
Regards,
Bernhard
Ranorex Support Team
.
Image