new, create, edit, update, and destroy actions behave correctly when an unauthenticated user attempts to access them.test/controllers/limericks_controller_test.rb - controller test file."should not get new if not authenticated" - name of new new test."should not create limerick if not authenticated" - name of new create test."should not get edit if not authenticated" - name of new edit test."should not update limerick if not authenticated" - name of new update test."should not destroy limerick if not authenticated" - name of new destroy test.assert_response - check that the HTTP response has a redirect status code.assert_redirected_to - check that the HTTP redirect was to the Devise sign-in page.
new_user_session_url - the URL helper for the Devise sign-in page.assert_not_nil - check that a flash['alert'] message was set.rails test -v - command to run tests.rails test -v showing that the controller tests ran and passed.