1
0
mirror of https://github.com/astaxie/beego.git synced 2024-11-22 08:40:54 +00:00

fix go1.10.3 orm test failed

This commit is contained in:
astaxie 2018-07-20 22:45:44 +08:00
parent 81f69f12ab
commit 868fc2a29f
2 changed files with 48 additions and 44 deletions

View File

@ -2,7 +2,7 @@ language: go
go:
- "1.9.2"
- "1.10.2"
- "1.10.3"
services:
- redis-server
- mysql

View File

@ -433,11 +433,8 @@ var (
dDbBaser dbBaser
)
func init() {
Debug, _ = StrTo(DBARGS.Debug).Bool()
if DBARGS.Driver == "" || DBARGS.Source == "" {
fmt.Println(`need driver and source!
var (
helpinfo = `need driver and source!
Default DB Drivers.
@ -479,7 +476,14 @@ export ORM_DRIVER=tidb
export ORM_SOURCE='memory://test/test'
go test -v github.com/astaxie/beego/orm
`)
`
)
func init() {
Debug, _ = StrTo(DBARGS.Debug).Bool()
if DBARGS.Driver == "" || DBARGS.Source == "" {
fmt.Println(helpinfo)
os.Exit(2)
}