Go语言高级窍门与技巧,看完你也能写出高质量代码

Ben Johnson’s tip. Using *_test package doesn’t allow you to enter unexported identifiers. This puts you into position of a package’s user, allowing you to check whether package’s public API is useful.当你有一些运行很慢的测试时,等待所有测试完成会变得很烦人,特别是当你想立刻知道编译是否成功时。

网站地图