we are writing an application accessing a database of an erp-solution. Of course we are not allowed to write into the database (database = readonly).
This leads to a conflict when writing tests for our daos that access/read the database.
What are best practices to generate testdata?
Any suggestions would be appriciate, thanks in advance
Tobi
Update:
Maybe important, we don’t map all the properties of the tables in the erp’s database because we won’t need them. Some of the not mapped columns are not null.
Use a non production database. If possible use an in-memory database, use something like DB Unit to create the schema and standing data and let the instance tear itself down when the test pack is complete.