I am trying to use dbunit with AbstractTransactionalDataSourceSpringContextTests to write an end to end integration test. I am using hibernate as the persistence framwork. I am running into problems where hibernate is not flushing to the db so that my tests fail when i assert through dbunit. I think this has to do with hibernate set to auto flush.
I really don't want to do an explict flush in my dao nor do i want the hibernate session to be set to eager flush, and even that doesn't seem to work when i do a delete, which is odd.
Has anyone else run into this problem? I am using hibernate 3.0.2 and spring 1.2rc2.
Also I do want to know whether this stratergy of checking the result is the norm or do people just use hibernate to test the result. If I use hibernate to test the result everything works fine.
Thanks,
Umesh


Reply With Quote