Home » Tag Archives: dbUnit

Tag Archives: dbUnit

Spring from the Trenches: Using Null Values in DbUnit Datasets

dbunit-logo

If we are writing integration tests for an application that uses Spring Framework, we can integrate DbUnit with the Spring testing framework by using Spring Test DbUnit. However, this integration is not problem free. Often we have to insert null values to the database before our tests are run or verify that the value saved to the specific table column ...

Read More »

DBUnit, Spring and Annotations for Database testing

dbunit-logo

If you have ever tried writing database tests in Java you might have come across DBUnit. DBUnit allows you to setup and teardown your database so that it contains consistent rows that you can write tests against. You usually specify the rows that you want DBUnit to insert by writing a simple XML document, for example:         ...

Read More »

DB unit testing with dbUnit, JSON, HSQLDB and JUnit Rules

dbunit-logo

In this week’s run of my TDD course, I thought it would be interesting to write a little fixture to make it easier to use dbUnit. My original thought was just to teach dbUnit about JSON, but it turns out that Lieven Doclo has done that already. So I decided to go a step further and also combine dbUnit with ...

Read More »
Want to take your Java Skills to the next level?
Grab our programming books for FREE!
  • Save time by leveraging our field-tested solutions to common problems.
  • The books cover a wide range of topics, from JPA and JUnit, to JMeter and Android.
  • Each book comes as a standalone guide (with source code provided), so that you use it as reference.
Last Step ...

Where should we send the free eBooks?

Good Work!
To download the books, please verify your email address by following the instructions found on the email we just sent you.