8cbea70e by astaxie

beego: hot fix for TestBeegoInit can't parsefile

1 parent f222f5b2
Showing 1 changed file with 5 additions and 0 deletions
...@@ -238,6 +238,11 @@ func initBeforeHttpRun() { ...@@ -238,6 +238,11 @@ func initBeforeHttpRun() {
238 func TestBeegoInit(apppath string) { 238 func TestBeegoInit(apppath string) {
239 AppPath = apppath 239 AppPath = apppath
240 AppConfigPath = filepath.Join(AppPath, "conf", "app.conf") 240 AppConfigPath = filepath.Join(AppPath, "conf", "app.conf")
241 err := ParseConfig()
242 if err != nil && !os.IsNotExist(err) {
243 // for init if doesn't have app.conf will not panic
244 Info(err)
245 }
241 os.Chdir(AppPath) 246 os.Chdir(AppPath)
242 initBeforeHttpRun() 247 initBeforeHttpRun()
243 } 248 }
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!