spec/controllers/controller_spec.rb in curupira-0.1.4 vs spec/controllers/controller_spec.rb in curupira-0.1.6

- old
+ new

@@ -1,9 +1,9 @@ require 'rails_helper' class BaseController < ApplicationController - before_filter :authorize + before_action :authorize end describe BaseController, type: :controller do let!(:current_user) { FactoryGirl.create(:user) } @@ -32,9 +32,10 @@ end context "when user have authorization" do it "user access the resource" do get :index - expect(assigns(:success)).to be true + expect(response).to be_success + expect(response).to have_http_status(200) end end end \ No newline at end of file