• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Best tools / tutorials to unit test Hibernate 3 / JPA objects?

 
James Dekker
Ranch Hand
Posts: 221
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What are the best tools to unit test Hibernate 3 and JPA objects?

So far, I've heard of EasyMock but have not tried it yet.

What's the preferred API / Library for Hibernate 3 / JPA specific unit testing?

Is there a tutorial or an article on JavaRanch which gives the reader a good exposure?

All my best...
 
Cameron Wallace McKenzie
author and cow tipper
Saloon Keeper
Posts: 4968
1
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here's an interesting article on unit testing with Hibernate and the Java Persistence API.

Testing Hibernate Applications

-Cameron McKenzie
 
James Dekker
Ranch Hand
Posts: 221
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks!
 
Daniel Näslund
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have used dbunit from my JUnit enviroment. No hazzle creating specific ant targets. I just put the jars in the lib-folder and created a base class for my tests that initialized the database with values from an xml-file.

The supplied link is a good starting point.

Unit testing database code
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic