@@ -18,13 +18,11 @@ import (
18
18
// Hook up gocheck into the "go test" runner.
19
19
func Test (t * testing.T ) { TestingT (t ) }
20
20
21
- type FunctionalSuite struct {
22
- }
21
+ type FunctionalSuite struct {}
23
22
24
23
var _ = Suite (& FunctionalSuite {})
25
24
26
25
func (s * FunctionalSuite ) SetUpSuite (c * C ) {
27
-
28
26
}
29
27
30
28
func (s * FunctionalSuite ) TestSemanticVersionColumnDiscard (c * C ) {
@@ -111,7 +109,7 @@ func (s *FunctionalSuite) TestEnvironmentSettingWithSecretsFiles(c *C) {
111
109
c .Assert (err , IsNil )
112
110
defer UnsetEnvironment (c , "DATA_SOURCE_URI" )
113
111
114
- var expected = "postgresql://custom_username$&+,%2F%3A;=%3F%40:custom_password$&+,%2F%3A;=%3F%40@localhost:5432/?sslmode=disable"
112
+ expected : = "postgresql://custom_username$&+,%2F%3A;=%3F%40:custom_password$&+,%2F%3A;=%3F%40@localhost:5432/?sslmode=disable"
115
113
116
114
dsn := getDataSources ()
117
115
if len (dsn ) == 0 {
@@ -165,7 +163,7 @@ func (s *FunctionalSuite) TestEnvironmentSettingWithDnsAndSecrets(c *C) {
165
163
// test DSN including SSL enabled
166
164
func (s * FunctionalSuite ) TestSSL (c * C ) {
167
165
// Thr driver doesn't support sslmode=prefer
168
- envDsn := "postgresql:// root: root@localhost:5433/? sslmode=require"
166
+ envDsn := "host=127.0.0.1 port=5433 user= root password= root database=postgres sslmode=require"
169
167
err := os .Setenv ("DATA_SOURCE_NAME" , envDsn )
170
168
c .Assert (err , IsNil )
171
169
defer UnsetEnvironment (c , "DATA_SOURCE_NAME" )
@@ -196,7 +194,6 @@ func (s *FunctionalSuite) TestSSL(c *C) {
196
194
197
195
db , err := sql .Open ("postgres" , dsn [0 ])
198
196
c .Assert (err , IsNil )
199
- //v95 := semver.MustParse("9.5.0")
200
197
version , err := postgresVersion (db )
201
198
c .Assert (err , IsNil )
202
199
if version < 90500 {
@@ -328,7 +325,6 @@ func UnsetEnvironment(c *C, d string) {
328
325
329
326
// test boolean metric type gets converted to float
330
327
func (s * FunctionalSuite ) TestBooleanConversionToValueAndString (c * C ) {
331
-
332
328
type TestCase struct {
333
329
input interface {}
334
330
expectedString string
0 commit comments