xiaofans / robotium

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

ClickOnWebElement won't work on dynamically created dropdownmenu options #481

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1.Load a dynamically created dropdown menu (<select> tag) options(<option> tag) 
into a cordova webview container
2.Try solo.ClickOnWebContent(By.id(..)); (Yes ids are also dynamically created)
3.solo doesn't find the item.

What is the expected output? What do you see instead?
Test fails because solo doesn't find the webelement

What version of the product are you using? On what operating system?
4.2

Please provide any additional information below.
I debugged the source code and Solo does not register the dynamically created 
elements at all. I guess it scans the source code before the javascript runs. 

Original issue reported on code.google.com by giraytu...@gmail.com on 4 Jul 2013 at 12:43

GoogleCodeExporter commented 9 years ago
i tried other By. options as well and none worked

Original comment by giraytu...@gmail.com on 4 Jul 2013 at 12:54

GoogleCodeExporter commented 9 years ago
what i mean by "solo does not register the dynamically created elements at all" 
is that during debugging i realized that there is a method that returns all 
web-element on the page, and this method does not return the dynamically 
created <option> elements at all.

i hope it is more clear now.

Original comment by giraytu...@gmail.com on 4 Jul 2013 at 1:17

GoogleCodeExporter commented 9 years ago
Thanks for reporting this. Would it be possible for you to send me an app that 
exhibits this issue?

Original comment by renasr...@gmail.com on 5 Jul 2013 at 6:22

GoogleCodeExporter commented 9 years ago
Hi,

here is a link to the app: 
https://www.dropbox.com/s/n720p3sl5iuw7bh/ExampleApp.zip

let me know if you also need the source code.

Original comment by giraytu...@gmail.com on 5 Jul 2013 at 10:49