search for: normal_user

Displaying 2 results from an estimated 2 matches for "normal_user".

2005 Oct 27
0
has_one with Single Table Inheritance - NameError : uninitialized constant
...hlist.new(''title''=>''Default Wish List'') wishlist.user = self self.wishlist = wishlist end self.wishlist.items<<album self.wishlist.save end What''s strange is this works perfectly in my Wishlist unit test. def test_add_to_wishlist assert_nil @normal_user.wishlist album = Album.find(1) @normal_user.add_to_wishlist(album) assert_not_nil @normal_user.wishlist assert_equal 1, @normal_user.wishlist.items.length assert_equal album, @normal_user.wishlist.items[0] end no errors. passes all assertions. any ideas? _________________________________________...
2007 Sep 04
3
Model Specs: Fixtures vs Mocks + Stubs?
What is the general opinion about fixtures versus mocking and stubbing in model specs? I heard from agile on IRC that they save the database testing for integration testing, but I also see that the caboose sample applicaiton uses fixtures. I also noticed that on the rspec site, it says "Ironically (for the traditional TDD''er) these are the only specs that we feel should actually