1、go test config_test.go
,always file,error: open conf/config.yml: The system cannot find the path specified
2、source code is ok
3、how do go test file
sucess in different directory
去unittest无法加载文件
- 写回答
- 好问题 0 提建议
- 追加酬金
- 关注问题
- 邀请回答
-
1条回答 默认 最新
- douliangli6407 2016-12-08 06:36关注
Your working directory during tests is different.
You may want a workaround with dynamic calculation of the config dir path, for example: http://www.kaihag.com/external-assets-working-directories-and-go/
解决 无用评论 打赏 举报