Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    TabSet is not being selected by Selenium IDE when browser is out of focus

    Wondering if the following is an expected behavior.

    1. Recorded Selenium IDE script which included TabSet
    2. Played the script, Tab is not being selected visually. Since the fields/forms are on the same page just hidden, functionally (not looking at the screen) it all works just fine.
    3. Executed individual click on tab command:
    scLocator=//TabSet[ID="products_tabSet"]/tab[ID=products_tab2||title=Comments||index=2]/
    Nothing happened, no errors displayed.
    4. Clicked on the browser window to focus on it, tab changed.

    It seems that click command is executed but since the Selenium IDE window is in focus and main browser window is not, tabs didn't change visually but may have functionally.

    When I executed the script again only this time manually focused on the browser window, tabs were being changed visually as expected.

    Thanks.

    #2
    The browser running tests must have focus or many, many things won't work (this is just one of them).

    Comment


      #3
      Thanks. I actually found a solution how to focus on the window. For anyone else who struggles with this, add the following to your Selenium IDE script somewhere in the beginning:

      selectWindow
      windowFocus

      Target can be left blank in selectWindow() to allow it to select the main window.

      Comment

      Working...
      X