xiaofans / robotium

Automatically exported from code.google.com/p/robotium
0 stars 0 forks source link

Robotium click fails on cordova app with Dojo implementation #456

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Build a Dojo sample hybrid application (AFAIK worklight has cordova/phonegap 
framework and has capability to implement Dojo as well)
2. Run a simple testcase to click on a webelement 
3.

What is the expected output? What do you see instead?
Expected: next page loads

Actual: Nothing! Tests Fail because an element on the expected page isn't found.

What version of the product are you using? On what operating system?
Robotium 4.1 on Mac OS X 10.8.3, testing against android-15

Please provide any additional information below.

I've been using Robotium for a while now without many problems I couldn't work 
through. However, recently I started playing with an application that was built 
with Cordova/PhoneGap and it uses Dojo mobile library (JS lib that provides 
native look and feel). I've been experiencing the following problem, the web 
element is found by Robotium (using xpath locator) and the click occurs but the 
next page never loads. Looking at the emulator during the run I can see the 
click occur because the blue highlight is displayed on the element as it is 
clicked. After that nothing happens. No useful info is shown in the Logcat 
logs. 

I have also tried to click the screen coordinates of the web element without 
any success. I'm treating the application as a black box.

UPDATE: I managed to perform 1 click by calling 
getInstrumentation().callOnActivityResume(getActivity()); prior to click. All 
subsequent clicks fail again.

Original issue reported on code.google.com by mario....@gmail.com on 16 May 2013 at 1:42

GoogleCodeExporter commented 9 years ago
Thanks for reporting this. 

Original comment by renasr...@gmail.com on 17 May 2013 at 2:48

GoogleCodeExporter commented 9 years ago
This has been fixed in Robotium 4.2. 

Original comment by renasr...@gmail.com on 25 Jun 2013 at 4:23