Selenium WebDriver clicks JQuery mobile button, but does not load new page -


i trying use selenium webdriver automate mobile web app team creating our company using jquery. since using jquery mobile, of html retrieved in single request, , clicking on buttons brings new pages on default page.

the test writing should click button brings new request page:

defaultselenium selenium; ... selenium.click("css=a[href='#new-request-page']"); 

the driver seems finding button fine because selenium doesn't throw exceptions. however, no page ever pops on default page, user can't see going on. despite this, test seems keep running normal until runs later (unrelated) error.

is selenium finding , clicking new request button? if so, can driver load new request page? if not, why not letting me know can't find new request button?

i have read others may need tell test wait ajax calls finish before starting next step of test, next solution. however, wondering if else out there having similar issues.

unfortunately, cannot post link web app since exists on our intranet , requires company login view. test being carried out in firefox , using default selenium web driver.

firstly, seems selenium rc code, has been officially deprecated. consider switching webdriver.

using webdriver, implement this:

webelement jquerybutton = driver.findelement(by.cssselector("your_css")); 

see if returns anything, can try click on it, doesn't work out. need execute jquery native api functions. javascriptexecutor interface.

http://selenium.googlecode.com/git/docs/api/java/org/openqa/selenium/javascriptexecutor.html


Comments

Popular posts from this blog

html - How to style widget with post count different than without post count -

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

javascript - storing input from prompt in array and displaying the array -