suppress devise warnings on rspec tests

This commit is contained in:
Devin Howard 2016-01-26 18:47:42 +08:00
parent cc99ed001d
commit d64fe002dc

View file

@ -10,6 +10,7 @@ module ControllerHelpers
receive(:authenticate!).and_throw(:warden, scope: :user)
)
else # simulate authenticated
allow_message_expectations_on_nil
allow(request.env['warden']).to(
receive(:authenticate!).and_return(user)
)