Selenium IDE:Opening in new tab and shift focus to new tab not working -
i have stuck in 1 point in selenium ide
the scenario this
login----- go dashboard page--------- mouse on menu on top navigational bar---- on mouseover sub menu appear drop down-- click link drop down -- after clicking link open in new tab
now point on-wards have shift our focus new tab because rest of testing done on new tab.
the code have written given below
<tr> <td>open</td> <td>/magma/dev/</td> <td></td> </tr> <tr> <td>type</td> <td>name=user_id</td> <td>abcd</td> </tr> <tr> <td>type</td> <td>name=pass</td> <td>1234</td> </tr> <tr> <td>clickandwait</td> <td>id=btnlogin</td> <td></td> </tr> <tr> <td>verifytextpresent</td> <td>costing list</td> <td></td> </tr> <tr> <td>verifytextpresent</td> <td>fuel</td> <td></td> </tr> <tr> <td>mouseover</td> <td>//div[@id='smoothmenu1']/ul/li[3]</td> <td></td> </tr> <tr> <td>click</td> <td>link=fuel cost</td> <td></td> </tr> <tr> <td>selectwindow</td> <td>http://10.0.1.101/magma/dev/fuelcost/</td> <td></td> </tr> <tr> <td>verifytextpresent</td> <td>manage fuel cost</td> <td></td> </tr> <tr> <td>clickandwait</td> <td>link=logout</td> <td></td> </tr>
this code working correctly upto clicking sub menu dropdown after not working , error showing in log
so when ever trying run test case showing error
[warn] link has target '_blank', not supported in selenium! randomizing target be: selenium_blank84419
can 1 please me write code
the following code works me .
storeeval selenium.getallwindownames()[1] windowname
geteval this.doecho("array length: "+selenium.getallwindownames().length);this.doecho("available window names: "+selenium.getallwindownames());this.doecho("selecting window: "+storedvars['windowname']);
selectwindow ${windowname}
hope others face similar type problem
Comments
Post a Comment