Sha256: bdf3f3c80e78db1a34dea1939a93ca5295af50a287ef646e13ff42d53564e014
Contents?: true
Size: 987 Bytes
Versions: 12
Compression:
Stored size: 987 Bytes
Contents
# encoding: utf-8 require File.dirname(__FILE__) + '/spec_helper' describe "SelectLists" do before :each do browser.goto(WatirSpec.files + "/forms_with_input_elements.html") end describe "#length" do it "returns the correct number of select lists on the page" do browser.select_lists.length.should == 4 end end describe "#[]" do it "returns the correct item" do browser.select_lists[0].value.should == "2" browser.select_lists[0].name.should == "new_user_country" browser.select_lists[0].should_not be_multiple browser.select_lists[1].should be_multiple end end describe "#each" do it "iterates through the select lists correctly" do browser.select_lists.each_with_index do |l, index| browser.select_list(:index, index).name.should == l.name browser.select_list(:index, index).id.should == l.id browser.select_list(:index, index).value.should == l.value end end end end
Version data entries
12 entries across 12 versions & 1 rubygems