Method: RWebUnit::Assert#assert_option_equals
- Defined in:
- lib/rwebunit/assert.rb
#assert_option_equals(select_name, option_label) ⇒ Object Also known as: assert_select_label
148 149 150 151 152 153 154 155 156 157 |
# File 'lib/rwebunit/assert.rb', line 148 def assert_option_equals(select_name, option_label) @web_browser.select_lists.each { |select| next unless select.name == select_name select.o.each do |option| # items in the list if (option.text == option_label) then assert_equal(select.value, option.value, "Select #{select_name}'s value is not equal to expected option label: '#{option_label}'") end end } end |