Hibernate testing with DBUnit without hbm files -


i'm trying test app uses hibernate dbunit. tests run on in-memory db create-drop strategy.

i keep getting nosuchtableexception when dbunit tries feed db. examples found on web of combination (hibernate , dbunit) had database structure declared in *hbm files.

is mandatory have hbm files in order integrate hibernate dbunit?

cheers!

you don't need have hbm files.

what's happening dbunit creates in memory db, it's clean db. unable load data.

as part of setup code, need initialize hibernate before load data. can issuing call select 1 through hibernate api. force hibernate create tables, call dbunit setup populate them.


Comments

Popular posts from this blog

java - Run a .jar on Heroku -

java - Jtable duplicate Rows -

validation - How to pass paramaters like unix into windows batch file -