Method: AutoTest::Page.select_option
- Defined in:
- lib/page.rb
.select_option(id, input_texts, session) ⇒ Object
select a random option from a select list
215 216 217 218 219 220 221 |
# File 'lib/page.rb', line 215 def select_option(id, input_texts, session) = session.find_by_id(id).all('option').collect{ |o| o.text } i = rand(.size) input_texts << "select___"+id input_texts << [i].to_s session.select [i], :from => id end |