Sha256: 85fcda8819d22052666e3a4dcea66f8c9c75c5f84d5897388d4ec0a13a97ae0f
Contents?: true
Size: 812 Bytes
Versions: 1
Compression:
Stored size: 812 Bytes
Contents
require File.dirname(__FILE__) + '/spec_helper.rb' describe "Ps" do before :all do @browser = Browser.new(BROWSER_OPTIONS) end before :each do @browser.goto(HTML_DIR + "/non_control_elements.html") end describe "#length" do it "returns the number of ps" do @browser.ps.length.should == 5 end end describe "#[]" do it "returns the p at the given index" do @browser.ps[1].id.should == "lead" end end describe "#each" do it "iterates through ps correctly" do @browser.ps.each_with_index do |p, index| p.name.should == @browser.p(:index, index+1).name p.id.should == @browser.p(:index, index+1).id p.value.should == @browser.p(:index, index+1).value end end end after :all do @browser.close end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
caius-celerity-0.0.6.11 | spec/ps_spec.rb |