search for: students_controller_spec

Displaying 1 result from an estimated 1 matches for "students_controller_spec".

2007 Jul 17
12
Getting past my login system
...pec controllers that are behind the login system. Each page checks for the session[:user], and if they do not exists, requires them to login. Logging in is handled by one controller (the Admin controller) and I want to access a page under another controller (say a Students controller). In my students_controller_spec.rb, I want want to make sure http://test.host/students is successfully displayed, so I wrote something like: it "should be successful" do get :index response.should be_success end The problem is that is keeps redirecting to my login page at http://test.host/login. I trie...