甚至还可能会超过或少于您期望的调用次数。
It might even invoke them more or fewer times than you expect.
但如果您那样做了,就会注意到,这些方法未能在您期望的时间调用,或者未能按照您期望的次数被调用。
However, if you do so, be aware that these methods might not be called when or as many times as you expect.
如果某个mock方法的调用次数超过了期望值或是参数不正确你就会立刻看到一个错误。
You'll get an error immediately if a mock method is called more times than expected or with the wrong arguments.
应用推荐