I have some JDBC code for SQL databases and have written JUNIT tests for it. The tests are run through ant. The requirement is to have a small database that can form part of the test suite and be stored in the version control software's database so that when deployed the tests can be run automatically without having to access an external database. I have explored the option of using mock objects and require a real database so that protocol/driver issues can be tested. Does anyone know of a free database that can be used for this?
Joined: Dec 12, 2001
To test your driver, wouldn't you need a database that uses the same driver as whatever it is you're using as your application's database? There are several free databases out there, but I think your driver concern would be the big factor in determining which to use. Go out to Sun's site and look up your JDBC driver to see what other databases it may support - then use one of those. JDBC Drivers
Joined: Nov 26, 2002
Tina, Thanks for the reply and sorry about using confusing language while specfying my requirement. I have not developed a driver. I have just written some java code that uses standard SQL statements to query databases that support SQL. So I need to test this piece of code using such a database. I have found the HSQL database from http://hsqldb.sourceforge.net which I think should serve the purpose. Thanks again.