any chance that using savepoint/rollback could solve your issue? On Thursday, June 20, 2019 at 11:32:38 AM UTC+2, Niklas Mehner wrote: > > Hi, > > We are using H2 for end-to-end tests for our JEE application. > > So basically the setup is: > > * start H2 (in memory) and application server > * run many testcases > * stop H2 and application server > > Each testcase brings its own data and clears all tables before running. > Although H2 is pretty fast the setup of the data takes some time. > > What I am thinking about is finding a way to start H2 e.g. from a file > that contains some prefilled data and then only add the special data the > test needs on top. > But I have not found any way to reset the database to the initial state > after the test. > Of course copying the file again and restarting H2 would work, but this is > probably also slow when running very many tests. > > Has anybody a similar setup and have you solved this problem somehow? > Running in-memory but backed by a read-only file for example? > > Thanks & best regards, > Niklas > >
-- You received this message because you are subscribed to the Google Groups "H2 Database" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/h2-database/b56ccdb4-2b52-408b-a275-3e842e19a0d8%40googlegroups.com.
