Closed hotrush closed 2 months ago
go-txdb only works with database/sql
drivers. pgxpool does not use this interface. pgx does provide a compatibility layer for database/sql
, but as far as I'm aware, that's completely independent from pgxpool, since database/sql
handles its own pool.
@hotrush you might want to take a look at my project pgtestdb — the pgtestdb.Custom()
method will let you create a new test database, then connect to it with pgxpool.
@peterldowns thanks for the hint, already switched to it. Much better than txdb 👍
Any hint much appreciated