Sha256: 59dc0a22f8db9466cd05d0e86817e5653d1d9345d6676b7fe1282b2efef6bffb

Contents?: true

Size: 695 Bytes

Versions: 2

Compression:

Stored size: 695 Bytes

Contents

require 'spec_helper'

describe Symbiont::WebObjects::Heading do
  describe "implementation" do
    let(:heading_object) { Symbiont::WebObjects::Heading }

    it "should allow locators to be used" do
      [:class, :id, :index, :xpath, :name].each do |t|
        locator = heading_object.provide_locator_for t => 'value'
        locator.keys.first.should == t
      end
    end

    it "should register with an h1 tag" do
      ::Symbiont::WebObjects.get_class_for(:h1).should == ::Symbiont::WebObjects::Heading
    end

    it "should register with an h2 tag" do
      ::Symbiont::WebObjects.get_class_for(:h2).should == ::Symbiont::WebObjects::Heading
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
symbiont-0.2.1 spec/symbiont/web_objects/heading_spec.rb
symbiont-0.2.0 spec/symbiont/web_objects/heading_spec.rb