I have service classes based on Entity Framework 4. I'd like to test them on a database filled with pre-generated sample data. The problem is: I would like the tests, whether passed or failed, to not actually touch the database, so that it may be re-used for other tests.
Thus I'd like ObjectContext.SaveChanges to pretend that everything's fine, and keep the changes in memory, but silently omit their actual persistence in the data source. Is this possible?
P.S. I am aware of the repository pattern, but would not like to use it in this case.