If I have a Devise model User, of which only those users with role :admin are allowed to view a certain url, how can I write an RSpec integration test to check that the status returns 200 for that url? def login(user) post user_session_path, :email => user.email, :password => 'password' end This was pseudo-suggested in the answer to this question: Stubbing authentication in request spec, but I can

{{#tags}}- {{label}}
{{/tags}}