~/talk

Lightning-Fast Database Tests

Talkat GopherCon 2024 · 2024-07-07..07-10· [testing, databases]
links:none on file
slides:none on file

Library called PG test DB uses template databases to spin up isolated ephemeral Postgres instances for each test, integrating with pgx and migration tools like golang-migrate. Template build time is about 0.5s and cloning a new database is ~10 ms, enabling parallel tests and avoiding teardown. Benchmarking shows a best-case ~5× speedup when combined with tmpfs and fsync disabled; failed tests preserve their databases for inspection while successful ones are deleted.

AI-written summary · about

~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.