logoalt Hacker News

odie5533today at 4:05 PM1 replyview on HN

For unit testing, I still use TestContainers which spins a full Postgres in Docker. But new alternatives like this make py-pglite (https://github.com/wey-gu/py-pglite) possible which is Python unit testing with PGlite. Even so, for Python unit testing I'm more confident in something like pgserver (https://github.com/orm011/pgserver) which offers the full, real Postgres in a lightweight pip package. Note: my take is specifically for unit testing, not other use cases!


Replies

theptiptoday at 4:19 PM

What are the trade-offs you’ve seen between the two? Always appreciate this sort of experience report on HN!