selenium webdriver - How to get the current URL in Robot framework? -
when 'apply' link clicked, opens new browser in robot framework. how current url of page? here code:
open server set browser implicit wait 60 go ${server}/jobs element should visible xpath=.//*[@id='txtjobsearch'] input text xpath=.//*[@id='txtjobsearch'] ${job title search} element should contain xpath=(.//*[@class='clearfix tit-job']/div)[1] ${job title} element should visible xpath=(.//*[@class='btn btn-sm btn-primary btnapply'])[1] click element xpath=(.//*[@class='btn btn-sm btn-primary btnapply'])[1]
after line, opens new window. how url of newly opened page , actions input text?
set browser implicit wait 20 wait until page contains element xpath=.//*[@class='text-primary']
have tried using select window keyword?
http://rtomac.github.io/robotframework-selenium2library/doc/selenium2library.html#select%20window
click link popup_link # opens new window select window popupname title should popup title select window # chooses main window again
it seems wish verify url of new window should possible following:
select window | url=https://google.com
obviously need replace above url you're expecting. let know how on.
Comments
Post a Comment