Hi all, I'm just starting to work w/ RSpec, so I hope this question isn't too obvious or missing the point somehow: Is there a way in RSpec to specify that a controller action should use a specific HTTP status code? Specifically I want to test for the usage of 301 as opposed to 302, for a permanent redirection.
response.should be_redirect looks like it calls ActionController::TestRequest#redirect?, which is only testing for a status code from 300..399. In an old-fashioned Test::Unit Rails test I could do assert_response, but I can't see anything matching that in RSpec. Is there a less-documented feature I'm missing? Thanks, Francis Hwang http://fhwang.net/ _______________________________________________ rspec-users mailing list [email protected] http://rubyforge.org/mailman/listinfo/rspec-users
