[http://www.dbunit.org/ DbUnit] is a very handy tool for inserting test data into your database or confirming data after your tests. Sometimes, however, you run into gotchas.

    public void nontestExportDtd() throws Exception {
        IDatabaseConnection connection = getConnection();
        FlatDtdDataSet.write(connection.createDataSet(),
                new FileOutputStream(XML_DATASET_ROOT+"test.dtd"));
    }