Sha256: dc707e89fd55e7fe935d2868b683255dee2bc50c909bf829c9b4ec18c6359133

Contents?: true

Size: 450 Bytes

Versions: 9

Compression:

Stored size: 450 Bytes

Contents

require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')

describe HomeController do
  render_views

  describe "when Anonymous" do
    it "should redirect to login" do
      get :index
      response.should redirect_to(new_user_session_path)
    end
  end

  describe "when authenticated" do
    before do
      sign_in Factory(:user)
    end

    it "should render" do
      get :index
      assert_response :success
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
social_stream-0.3.6 spec/controllers/home_controller_spec.rb
social_stream-0.3.5 spec/controllers/home_controller_spec.rb
social_stream-0.3.4 spec/controllers/home_controller_spec.rb
social_stream-0.3.3 spec/controllers/home_controller_spec.rb
social_stream-0.3.2 spec/controllers/home_controller_spec.rb
social_stream-0.3.1 spec/controllers/home_controller_spec.rb
social_stream-0.3.0 spec/controllers/home_controller_spec.rb
social_stream-0.2.3 spec/controllers/home_controller_spec.rb
social_stream-0.2.2 spec/controllers/home_controller_spec.rb