DEV Community

Discussion on: Unit testing NestJS with Typeorm in memory

Collapse
 
bassochette profile image
Julien Prugne

From my researches you can't run postgres in memory.
This solution, is not optimal even with mysql more a trick to simplify a bit testing and ci setup.

Imo, you should setup a test db and reset it between tests. You'd be able to test all those neat postgres features. It's more complicated and add some ci setup but should be worth it.