18 January 2026:
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
q: new tab opens in new broser
Hello,
When I click on a link, it opens the tab in a new browser. how can I verify the url in that new browser?
I tried:
var $link = _getText(_link("fromurl"));
_click(_link("fromurl")); //it opens the tab in other browser
var $getBaseURL = _getBaseUrl();
_assertEqual($link, $getBaseURL); //but $getBaseURL is the url from where i started, not the url from the page that opened.
Can someone help?
When I click on a link, it opens the tab in a new browser. how can I verify the url in that new browser?
I tried:
var $link = _getText(_link("fromurl"));
_click(_link("fromurl")); //it opens the tab in other browser
var $getBaseURL = _getBaseUrl();
_assertEqual($link, $getBaseURL); //but $getBaseURL is the url from where i started, not the url from the page that opened.
Can someone help?
Best Answer
-
Hi loana,
Please try adding:
after the following line:_selectWindow("<title_of_your_new_window>");_click(_link("fromurl"));
Please let me know if it works for you.
Regards.
This discussion has been closed.
Answers
Regards.
Will be closing this discussion now!
Regards.