So, you add new code to authenticate various access, and your functional tests stop working.. You need to authenticate!
Add this to your test_helper.rb:
(the details are split out because we used them in other places too)
then add a call to “user1_login” to your functional tests, or if all of them need it, to the “def setup”.
Remember to write tests for not being logged in, and for situations where the logged in user should not have access to some protected resource.