Sha256: d681cb00bec56b8b86f905b0da3d74de14b3e99019e702bde3f032883bfd66ab
Contents?: true
Size: 726 Bytes
Versions: 2
Compression:
Stored size: 726 Bytes
Contents
require 'spec_helper' require 'fixtures/components/foo-renderer/models/envelope' describe Alephant::Renderer::Views::Envelope do let(:data) do { 'foo' => 'envelope' } end describe '#content_type' do it 'sets the correct content type' do expect(MyApp::Envelope.new(data).content_type).to eq('application/json') end end describe '#render' do it 'returns generated envelope' do expected_result = '{"head":["some/css/asset/path","some/js/asset/path"],"bodyInline":"<h1>Hello, I\'m a envelope template</h1>","bodyLast":["some/thing/to/add/after/body","some/other/thing/to/add/after/body"]}' expect(MyApp::Envelope.new(data).render).to eq(expected_result) end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
alephant-renderer-3.2.0 | spec/views_envelope_spec.rb |
alephant-renderer-3.1.0 | spec/views_envelope_spec.rb |