Browse Source

fix tests (#1429)

tags/v0.7.7
Lunny Xiao GitHub 2 months ago
parent
commit
d4419ac496
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 6 deletions
  1. +2
    -6
      dialect_postgres_test.go

+ 2
- 6
dialect_postgres_test.go View File

@@ -4,9 +4,8 @@ import (
"reflect"
"testing"

"xorm.io/core"
"github.com/jackc/pgx/stdlib"
"github.com/stretchr/testify/assert"
"xorm.io/core"
)

func TestParsePostgres(t *testing.T) {
@@ -72,10 +71,7 @@ func TestParsePgx(t *testing.T) {
}

// Register DriverConfig
drvierConfig := stdlib.DriverConfig{}
stdlib.RegisterDriverConfig(&drvierConfig)
uri, err = driver.Parse("pgx",
drvierConfig.ConnectionString(test.in))
uri, err = driver.Parse("pgx", test.in)
if err != nil && test.valid {
t.Errorf("%q got unexpected error: %s", test.in, err)
} else if err == nil && !reflect.DeepEqual(test.expected, uri.DbName) {


Loading…
Cancel
Save