TEST: Before you've written any of the code, you know how you want it to behave. You have a specification for its behavior. 为什么需要测试 当我们给程序添加了新功能后,可以run test来判断,新代码是否破坏了原有的程序. a well-writen test能帮助,其他开发者,更容易理清程序是如何工作的. TDD: test-driven development BDD…
Angular测试遇到的小坑 Error: Expected to be running in 'ProxyZone', but it was not found 检查doneFn的写法是否正确,位置是否正确,是否定义为undefined Unhandled Promise rejection: 'expect' was used when there was no current spec - Google Search 检查donfFn或者asyn是否使用正确,如果是测试异步方法,expec…