Class: Selenium::WebDriver::Alert
- Inherits:
-
Object
- Object
- Selenium::WebDriver::Alert
- Defined in:
- lib/selenium/webdriver/common/alert.rb
Instance Method Summary collapse
- #accept ⇒ Object
- #dismiss ⇒ Object
-
#initialize(bridge) ⇒ Alert
constructor
A new instance of Alert.
- #send_keys(keys) ⇒ Object
- #text ⇒ Object
Constructor Details
#initialize(bridge) ⇒ Alert
Returns a new instance of Alert.
5 6 7 |
# File 'lib/selenium/webdriver/common/alert.rb', line 5 def initialize(bridge) @bridge = bridge end |
Instance Method Details
#accept ⇒ Object
9 10 11 |
# File 'lib/selenium/webdriver/common/alert.rb', line 9 def accept @bridge.acceptAlert end |
#dismiss ⇒ Object
13 14 15 |
# File 'lib/selenium/webdriver/common/alert.rb', line 13 def dismiss @bridge.dismissAlert end |
#send_keys(keys) ⇒ Object
17 18 19 |
# File 'lib/selenium/webdriver/common/alert.rb', line 17 def send_keys(keys) @bridge.setAlertValue keys end |
#text ⇒ Object
21 22 23 |
# File 'lib/selenium/webdriver/common/alert.rb', line 21 def text @bridge.getAlertText end |