Sha256: c2c18e63041794bf9785b0c1a32dd5f5b5d4069235886bf12b5ab454c00d2d11
Contents?: true
Size: 750 Bytes
Versions: 1
Compression:
Stored size: 750 Bytes
Contents
# encoding: utf-8 require File.expand_path('spec_helper', File.dirname(__FILE__)) describe "Images" do before :each do browser.goto(WatirSpec.files + "/images.html") end describe "#length" do it "returns the number of images" do browser.images.length.should == 9 end end describe "#[]" do it "returns the image at the given index" do browser.images[5].id.should == "square" end end describe "#each" do it "iterates through images correctly" do count = 0 browser.images.each_with_index do |c, index| c.id.should == browser.image(:index, index).id c.value.should == browser.image(:index, index).value count += 1 end count.should > 0 end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
watir-webdriver-0.0.7 | spec/watirspec/images_spec.rb |