Nallamani, when are you checking for the data? Philp's point about
transactions is that all the data is rolled back out of the db after
the test. If you're expecting to look at the table after the testing
is done you won't see anything.
And you will continue to spend quality time with them!
> Is there any way to delay the roll back .
Almost all testing on databases should roll the database back after each test case. The only general exception I can think of is tests that help build a new database engine.
What do you want to do with that data, in the database? If you intend to inspect it, then you should add a .should (or an assertion) to your test case, to inspect that data automatically. Then the transaction will work for you, not against you.
If you are putting the data in the database for some non-test purpose, look at migrations.
> With normal integration testing I can store in database .
Your test_helper.rb may have had use_transactional_fixtures = false.