Why DbUnit

Here is the original message posted by ManuelLaflamme announcing the release of DbUnit 1.0:

I just released the first version of dbUnit, a database testing framework. This is a JUnit extension that sets up your database in a known state before executing your tests. This framework uses xml datasets (collection of data tables) and performs database operations before and after each test. The dbUnit framework supports both the "clean insert" and the "refresh" strategies.
Why?
I was responsible to define the unit testing strategy for a new J2EE project involving databases. I found that Cactus was a great JUnit extension to test EJB components and JSP/servlets but, even with a lot of research, I haven't found any products to set up our database in a consistent state before each test. I also discovered Richard Dallaway website (http://www.dallaway.com/acad/dbunit.html), which I found a very valuable resource. This enlightens me about the various testing strategies for database development (many of them coming from the JUnit mailing list). But at my knowledge, nothing exists yet that facilitates their application. At the end, I decided to do it myself and I created dbUnit!
For more information about dbUnit and to download it, go at http://dbunit.sourceforge.net
Any feedback you may have is welcome and much appreciated. I hope you will find dbUnit a valuable addition for the community.

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License