Sha256: ce932a45e3e4e3ef5b7a0521366f9ff101bf6e1f5c2957fe961ff998cec90e5d

Contents?: true

Size: 721 Bytes

Versions: 3

Compression:

Stored size: 721 Bytes

Contents

require 'spec_helper'

shared_examples_for 'a nested element' do |clazz|

  before(:each) do
    @nested_element = clazz.new
  end

  it 'has a parent element - #parent_element' do
    @nested_element.should respond_to(:parent_element)
  end

   it 'can get and set its parent element - #parent_element, #parent_element=' do
     @nested_element.parent_element = :some_parent_element
     @nested_element.parent_element.should == :some_parent_element
     @nested_element.parent_element = :some_other_parent_element
     @nested_element.parent_element.should == :some_other_parent_element
   end

  it 'starts with no parent element' do
    @nested_element.parent_element.should == nil
  end

end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
cucumber_analytics-1.2.0 spec/unit/nested_element_unit_specs.rb
cucumber_analytics-1.1.1 spec/unit/nested_element_unit_specs.rb
cucumber_analytics-1.0.0 spec/unit/nested_element_unit_specs.rb