sassernetsky / robotium

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

problem in scrolling the web page #601

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1.enable to find the webelement when its not visible on the device.
2.enable to scroll down all the scroll method we have already used
3.

What is the expected output? What do you see instead?
its crashing the project and said element not found
exception

What version of the product are you using? On what operating system?
we are using robotium 5.1 

Please provide any additional information below.

Original issue reported on code.google.com by prabji...@gmail.com on 6 May 2014 at 7:14

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

Original comment by renasr...@gmail.com on 6 May 2014 at 8:08

GoogleCodeExporter commented 9 years ago
Hi,I cannot share the app as its not allowed. but I will explain my problem I 
am testing a website with robotium its working fine with 3 pages but when eh 
4th page load its read the element from that page also but there is next button 
on the page which is not visible on the screen for that i have used 
solo.scrollToSide(Solo.RIGHT);
solo.scrollDown(); even solo.scrollUP(); teh scrolling is working fine with 
left and right but its not showing the next button which is on the bottom of 
screen. 

Original comment by prabji...@gmail.com on 6 May 2014 at 9:05

GoogleCodeExporter commented 9 years ago
Unfortunately nothing can be done about this. Robotium tells the WebView 
directly to scroll by: WebView.pageDown. What you will have to do is to use a 
manual solo.drag() in order to drag the screen down. 

Original comment by renasr...@gmail.com on 6 May 2014 at 9:27

GoogleCodeExporter commented 9 years ago
but I have used solo.drag() method also but it didn't work for that.

Original comment by prabji...@gmail.com on 6 May 2014 at 10:35

GoogleCodeExporter commented 9 years ago
That is unfortunately the only way around that I can think of. 

Original comment by renasr...@gmail.com on 6 May 2014 at 10:36

GoogleCodeExporter commented 9 years ago
but its scrolling right left and all but the problem is that it will not get 
the next button which is down in the web page, 

Original comment by prabji...@gmail.com on 6 May 2014 at 10:40

GoogleCodeExporter commented 9 years ago
You could try to enable Config.useJavaScriptToClickWebElements. Please see the 
Javadoc for more information. 

Original comment by renasr...@gmail.com on 6 May 2014 at 10:43

GoogleCodeExporter commented 9 years ago
hi, i ahve use web.zoomout() in my main UI thread which help the webpage to 
zoom out and make visible the elemnet on the screen but now on another page the 
zoomout() is zooming the page but the page is so large that eh element is not 
visible on the screen. My wondering why the scroll method of solo is not 
scrolling the web page. Please help me to scroll the web page

Original comment by prabji...@gmail.com on 9 May 2014 at 7:00

GoogleCodeExporter commented 9 years ago
I have solved that problem by writing the  
config.useJavaScriptToClickWebElements= true; in the main test method 

Original comment by prabji...@gmail.com on 12 May 2014 at 5:50