Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
Edgar Gutierrez
2,836 PointsProgramming -> Build a Simple Ruby on Rails Application -> Testing the whole app -> Testing the statuses controller
I'm getting the following failure.
1) Failure: test_should_be_logged_in_to_post_a_status(StatusesControllerTest) [test/functional/statuses_controller_test.rb:29]: Expected response to be a redirect to http://test.host/users/sign_in but was a redirect to http://test.host/statuses/980190963
This is how my statuses_controller_test.rb window looks like.
test "should be logged in to post a status" do
post :create, status: {context: "Hello"}
assert_response :redirect
assert_redirected_to new_user_session_path <-- This is line 29
end
1 Answer
Edgar Gutierrez
2,836 PointsNevermind, it now works :)