lib/testcentricity/app_elements/checkbox.rb in testcentricity-2.4.3 vs lib/testcentricity/app_elements/checkbox.rb in testcentricity-3.0.0

- old
+ new

@@ -6,11 +6,11 @@ end def checked? obj = element object_not_found_exception(obj) - obj.attribute('checked') == 'true' + obj.selected? end # Set the check state of a checkbox object. # # @example @@ -31,12 +31,12 @@ def set_checkbox_state(state) obj = element object_not_found_exception(obj) if state - obj.click unless obj.attribute('checked') == 'true' + obj.click unless obj.selected? else - obj.click if obj.attribute('checked') == 'true' + obj.click if obj.selected? end end end end