Sha256: 42efa5648a380a68c1f750517dc22f0226f7c09e46b47450e388dce9e848eca9

Contents?: true

Size: 882 Bytes

Versions: 21

Compression:

Stored size: 882 Bytes

Contents

require 'spec_helper'

describe Alchemy::EssencesHelper do

	before(:each) do
	  @element = Factory(:element)
		@element.content_by_name('intro').essence.update_attributes(:body => 'hello!')
	end

	it "should render an essence" do
	  content = @element.content_by_name('intro')
    render_essence(content).should match(/hello!/)
	end

	it "should render an essence view" do
	  content = @element.content_by_name('intro')
    render_essence_view(content).should match(/hello!/)
	end

  it "should render an essence view by name" do
    render_essence_view_by_name(@element, 'intro').should match(/hello!/)
  end

  it "should render an essence view by type" do
    render_essence_view_by_type(@element, 'EssenceText').should match(/hello!/)
  end

  it "should render an essence view by position" do
    render_essence_view_by_position(@element, 1).should match(/hello!/)
  end

end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
alchemy_cms-2.1.12 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.11 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.9.1 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.9 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.8.1 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.8 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.7 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.6 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.5 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.4 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.3 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.2 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.1 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.rc6 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.rc5 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.rc4 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.rc3 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.rc2 spec/helpers/essences_helper_spec.rb
alchemy_cms-2.1.beta6 spec/helpers/essences_helper_spec.rb