DEV Community

Discussion on: Creating new PostgreSQL DB for every xUnit test

Collapse
 
vbilopav profile image
vbilopav

That's interesting, new database for each test. I never thought of it. I wonder how it performs vs transaction per test. Thanks

Thread Thread
 
davidkudera profile image
David Kudera

Performance-wise new database will be slower. The first step is creating a new template database. Cloning that template database for each test is fast and runs in parallel. But you made me curious, I'll try to measure the impact.