Make ConnectionParameters fields public
This commit is contained in:
@@ -6,7 +6,7 @@ import (
|
||||
)
|
||||
|
||||
func createConnectionPool(maxConnections int) *ConnectionPool {
|
||||
connectionOptions := ConnectionParameters{socket: "/private/tmp/.s.PGSQL.5432", user: "pgx_none", database: "pgx_test"}
|
||||
connectionOptions := ConnectionParameters{Socket: "/private/tmp/.s.PGSQL.5432", User: "pgx_none", Database: "pgx_test"}
|
||||
pool, err := NewConnectionPool(connectionOptions, maxConnections)
|
||||
if err != nil {
|
||||
panic("Unable to create connection pool")
|
||||
@@ -15,7 +15,7 @@ func createConnectionPool(maxConnections int) *ConnectionPool {
|
||||
}
|
||||
|
||||
func TestNewConnectionPool(t *testing.T) {
|
||||
connectionOptions := ConnectionParameters{socket: "/private/tmp/.s.PGSQL.5432", user: "pgx_none", database: "pgx_test"}
|
||||
connectionOptions := ConnectionParameters{Socket: "/private/tmp/.s.PGSQL.5432", User: "pgx_none", Database: "pgx_test"}
|
||||
pool, err := NewConnectionPool(connectionOptions, 5)
|
||||
if err != nil {
|
||||
t.Fatal("Unable to establish connection pool")
|
||||
|
||||
Reference in New Issue
Block a user