Sha256: b670391882264f56b0b792926301ea8a7aab923824a6ac5507e0d6e74c672cdc

Contents?: true

Size: 696 Bytes

Versions: 2

Compression:

Stored size: 696 Bytes

Contents

require 'spec_helper'

describe "private_posts/index" do
  before(:each) do
    assign(:private_posts, [
      stub_model(PrivatePost,
        :title => "Title",
        :body => "MyText",
        :published => false
      ),
      stub_model(PrivatePost,
        :title => "Title",
        :body => "MyText",
        :published => false
      )
    ])
  end

  it "renders a list of private_posts" do
    render
    # Run the generator again with the --webrat flag if you want to use webrat matchers
    assert_select "tr>td", :text => "Title".to_s, :count => 2
    assert_select "tr>td", :text => "MyText".to_s, :count => 2
    assert_select "tr>td", :text => false.to_s, :count => 2
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
simple_token_authentication-1.0.0.pre.5 test/dummy/spec/views/private_posts/index.html.erb_spec.rb
simple_token_authentication-1.0.0.beta.5 test/dummy/spec/views/private_posts/index.html.erb_spec.rb