Commit 3ac90df5 authored by astaxie's avatar astaxie

Merge pull request #1794 from youngsterxyf/issue1789

fix issue1789: when testing, load config explicitly and forcibly
parents 9e9671d8 549a39c4
......@@ -89,5 +89,6 @@ func TestBeegoInit(ap string) {
os.Setenv("BEEGO_RUNMODE", "test")
appConfigPath = filepath.Join(ap, "conf", "app.conf")
os.Chdir(ap)
LoadAppConfig(appConfigProvider, appConfigPath)
initBeforeHTTPRun()
}
......@@ -316,10 +316,6 @@ func LoadAppConfig(adapterName, configPath string) error {
return fmt.Errorf("the target config file: %s don't exist", configPath)
}
if absConfigPath == appConfigPath {
return nil
}
appConfigPath = absConfigPath
appConfigProvider = adapterName
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment