On 30 Oct 2008, at 16:37, daociyiyou wrote:
> > i have a conclusion to make sure,that is : when testing codes, only > the fixtures data are stored in the test database table after running > the test and the model saved during runing test method is not stored > in the test database table? For example: > ######### > def test_save > user=User.new(...) > user.save > end > ########## > After running the test method,the user is not stored in the test > database table? > right? Sort of. It is stored in the test database, but the entire test runs within a transaction, which is rolled back at the end of the test. Fred --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---