Sha256: fb62e0937a356e166b534e25f74ad24b33dd43d1914aed3f528838420eb057a9

Contents?: true

Size: 560 Bytes

Versions: 5

Compression:

Stored size: 560 Bytes

Contents

require 'rails_helper'

module Theblog
  RSpec.describe HomeController, :type => :controller do
    routes { Theblog::Engine.routes }

    describe "GET index" do
      let(:account){ FactoryGirl.create(:confirmed_account) }

      it "returns http success" do
        sign_in account
        get :index
        expect(response).to have_http_status(:success)
      end

      it "renders own template" do
        get :index
        expect(response).to have_http_status(:success)
        expect(response).to render_template(:index)
      end
    end

  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
theblog-0.0.2.3 spec/controllers/theblog/home_controller_spec.rb
theblog-0.0.2.2 spec/controllers/theblog/home_controller_spec.rb
theblog-0.0.2 spec/controllers/theblog/home_controller_spec.rb
theblog-0.0.1.1 spec/controllers/theblog/home_controller_spec.rb
theblog-0.0.1 spec/controllers/theblog/home_controller_spec.rb