add more tests for stores (#445)
This commit is contained in:
11
core/stores/clickhouse/clickhouse_test.go
Normal file
11
core/stores/clickhouse/clickhouse_test.go
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
package clickhouse
|
||||||
|
|
||||||
|
import (
|
||||||
|
"testing"
|
||||||
|
|
||||||
|
"github.com/stretchr/testify/assert"
|
||||||
|
)
|
||||||
|
|
||||||
|
func TestClickHouse(t *testing.T) {
|
||||||
|
assert.NotNil(t, New("clickhouse"))
|
||||||
|
}
|
||||||
@@ -7,6 +7,6 @@ import (
|
|||||||
|
|
||||||
const postgresDriverName = "postgres"
|
const postgresDriverName = "postgres"
|
||||||
|
|
||||||
func NewPostgres(datasource string, opts ...sqlx.SqlOption) sqlx.SqlConn {
|
func New(datasource string, opts ...sqlx.SqlOption) sqlx.SqlConn {
|
||||||
return sqlx.NewSqlConn(postgresDriverName, datasource, opts...)
|
return sqlx.NewSqlConn(postgresDriverName, datasource, opts...)
|
||||||
}
|
}
|
||||||
|
|||||||
11
core/stores/postgres/postgresql_test.go
Normal file
11
core/stores/postgres/postgresql_test.go
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
package postgres
|
||||||
|
|
||||||
|
import (
|
||||||
|
"testing"
|
||||||
|
|
||||||
|
"github.com/stretchr/testify/assert"
|
||||||
|
)
|
||||||
|
|
||||||
|
func TestPostgreSql(t *testing.T) {
|
||||||
|
assert.NotNil(t, New("postgre"))
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user