ruby - Click an alphabet key in watir -


i want open link in new tab. using watir, watir-webdriver , chrome. need press ctrl + t. how do ?

this not - browser.element.send_keys [:control, 't']

exception -

c:/blah/selenium-webdriver-2.33.0/lib/selenium/webdriver/common/keyboard.rb:48:i‌​n assert_modifier': "t" not modifier key, expected 1 of [:control, :shift, :a c:/blah/selenium-webdriver-2.33.0/lib/selenium/webdriver/common/keyboard.rb:25:i‌​n press'.... 

this kind of duplicate. selenium , watir solutions identical:

how open new tab using selenium webdriver java?

from 2nd answer: browser.element.send_keys(:control, 't')


Comments

Popular posts from this blog

python - No exponential form of the z-axis in matplotlib-3D-plots -

php - Best Light server (Linux + Web server + Database) for Raspberry Pi -

c# - "Newtonsoft.Json.JsonSerializationException unable to find constructor to use for types" error when deserializing class -