test that photosController#index succeeds without any photos

This commit is contained in:
Jonne Hass 2011-11-06 14:47:28 +01:00
parent b8dbf1d81e
commit 7556dccb91

View file

@ -35,6 +35,12 @@ describe PhotosController do
end
describe '#index' do
it "succeeds without any available pictures" do
get :index, :person_id => Factory(:person).id.to_s
response.should be_success
end
it "displays the logged in user's pictures" do
get :index, :person_id => alice.person.id.to_s
assigns[:person].should == alice.person