Class: Watir::Radio
- Inherits:
-
Input
- Object
- BaseElement
- HTMLElement
- Input
- Watir::Radio
- Defined in:
- lib/watir-webdriver/elements/radio.rb
Constant Summary
Constants inherited from BaseElement
BaseElement::IGNORED_ATTRIBUTES
Instance Method Summary collapse
-
#set ⇒ Object
Select this radio button.
-
#set? ⇒ Boolean
Is this radio set?.
Methods inherited from Input
#enabled?, #to_button, #to_checkbox, #to_radio, #to_select_list, #type
Methods inherited from BaseElement
attribute_list, #attribute_value, attributes, #click, #double_click, #driver, #element, #exists?, #fire_event, #flash, #focus, #html, #initialize, #inspect, #parent, #right_click, #run_checkers, #send_keys, #style, #tag_name, #text, typed_attributes, #value, #visible?
Methods included from Container
Methods included from XpathSupport
#element_by_xpath, #elements_by_xpath
Constructor Details
This class inherits a constructor from Watir::BaseElement
Instance Method Details
#set ⇒ Object
Select this radio button.
13 14 15 16 17 18 |
# File 'lib/watir-webdriver/elements/radio.rb', line 13 def set assert_exists assert_enabled @element.click unless set? end |
#set? ⇒ Boolean
Is this radio set?
24 25 26 27 |
# File 'lib/watir-webdriver/elements/radio.rb', line 24 def set? assert_exists @element.selected? end |