mirror of
https://github.com/astaxie/beego.git
synced 2025-07-05 04:20:21 +00:00
Refactoring: Move dev & prod runmodes to const
This commit is contained in:
@ -18,6 +18,7 @@ import (
|
||||
"os"
|
||||
"testing"
|
||||
|
||||
"github.com/astaxie/beego"
|
||||
"github.com/astaxie/beego/config"
|
||||
)
|
||||
|
||||
@ -65,7 +66,7 @@ func TestXML(t *testing.T) {
|
||||
t.Error(pi)
|
||||
t.Fatal(err)
|
||||
}
|
||||
if xmlconf.String("runmode") != "dev" {
|
||||
if xmlconf.String("runmode") != beego.DEV {
|
||||
t.Fatal("runmode not equal to dev")
|
||||
}
|
||||
if v, err := xmlconf.Bool("autorender"); err != nil || v != false {
|
||||
|
Reference in New Issue
Block a user