Skip to content
Better HN
Top
New
Best
Ask
Show
Jobs
Search
⌘K
undefined | Better HN
0 points
rubenv
5y ago
0 comments
Share
For PostgreSQL and Go, here's a package to spin up a temp in-mem PostgreSQL:
https://github.com/rubenv/pgtest/
0 comments
default
newest
oldest
aidos
5y ago
From memory, in Postgres, you could also have a copy of your base database and then copy it in for each test, which is seem to recall being fairly fast. It includes the data too.
Create database test_db template initial_db;
j
/
k
navigate · click thread line to collapse