fix circle ci for cockroach

This commit is contained in:
Lunny Xiao 2019-01-23 15:12:07 +08:00
parent ea611cb2b6
commit f337f2c215
No known key found for this signature in database
GPG Key ID: C3B7C91B632F738A
2 changed files with 2 additions and 2 deletions

View File

@ -1 +1 @@
go test -db=postgres -conn_str="postgresql://root@localhost:26257/xorm_test?sslmode=disable"
go test -db=postgres -conn_str="user=root port=26257 dbname=xorm_test sslmode=disable"

View File

@ -63,7 +63,7 @@ func createEngine(dbType, connStr string) error {
if err != nil {
return err
}
rows, err := db.Query(fmt.Sprintf("SELECT 1 FROM pg_database WHERE datname = 'xorm_test'"))
rows, err := db.Query("SELECT 1 FROM pg_database WHERE datname = 'xorm_test'")
if err != nil {
return fmt.Errorf("db.Query: %v", err)
}