Sha256: 816b8064682b7ea37ebc95b1629bbd455ae6097fae80af325838c03cd17c3f36

Contents?: true

Size: 812 Bytes

Versions: 4

Compression:

Stored size: 812 Bytes

Contents

require 'spec_helper'

module Enki

  describe "/admin/comments/show.html" do
    after(:each) do
      rendered.should be_valid_html5_fragment
    end

    it 'should render' do
      assign :comment, mock_model(Comment,
        :author                  => 'Don Alias',
        :author_url              => 'http://enkiblog.com',
        :author_email            => 'donalias@enkiblog.com',
        :body                    => 'Hello I am a post',
        :created_at              => Time.now
      )
      allow_message_expectations_on_nil
      assigns[:comment].stub!(:post).and_return(mock_model(Post,
        :title        => 'A post',
        :slug         => 'a-post',
        :published_at => Time.now
      ))
      render :template => '/enki/admin/comments/show', :formats => [:html]
    end
  end

end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
enki-engine-0.0.5 spec/views/admin/comments/show.html_spec.rb
enki-engine-0.0.4 spec/views/admin/comments/show.html_spec.rb
enki-engine-0.0.3 spec/views/admin/comments/show.html_spec.rb
enki-engine-0.0.2 spec/views/admin/comments/show.html_spec.rb