From ead0b3bcc458cec61c8d1d157a17d82e393c5434 Mon Sep 17 00:00:00 2001 From: Robin Houston Date: Fri, 3 Feb 2012 22:36:54 +0000 Subject: Return 404 for /feed/user/no_such_user Fixes #407. --- spec/controllers/track_controller_spec.rb | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'spec/controllers/track_controller_spec.rb') diff --git a/spec/controllers/track_controller_spec.rb b/spec/controllers/track_controller_spec.rb index ee974dedd..0dc5db607 100644 --- a/spec/controllers/track_controller_spec.rb +++ b/spec/controllers/track_controller_spec.rb @@ -134,6 +134,11 @@ describe TrackController, "when viewing RSS feed for a track" do assigns[:xapian_object].results[2][:model].should == info_request_events(:useless_outgoing_message_event) # created_at 2007-10-14 10:41:12.686264 end + it "should return NotFound for a non-existent user" do + lambda { + get :track_user, :feed => 'feed', :url_name => "there_is_no_such_user" + }.should raise_error(ActiveRecord::RecordNotFound) + end end describe TrackController, "when viewing JSON version of a track feed" do -- cgit v1.2.3