Documentation
¶
Overview ¶
Package testpostgres runs a real Postgres for tests from embedded-postgres' downloaded binaries, so the Postgres-backed tests need no docker daemon.
Index ¶
Constants ¶
This section is empty.
Variables ¶
ErrUnavailable means the server's binaries could not be had (the first run on a machine downloads them), which a caller treats as a skip. Anything else Start returns is a failure.
View Source
var Fast = map[string]string{
"max_connections": "500",
"fsync": "off",
"synchronous_commit": "off",
"full_page_writes": "off",
}
Fast trades durability for speed, for tests whose database dies with the run. A measurement leaves it out: Postgres' own defaults are what an operator gets.
Functions ¶
This section is empty.
Types ¶
type Server ¶
type Server struct {
// Host is "127.0.0.1:port".
Host string
Password string
// contains filtered or unexported fields
}
Server is a running Postgres reachable on loopback only, with a password nothing else knows.
Click to show internal directories.
Click to hide internal directories.