(call *Call)
| 649 | } |
| 650 | |
| 651 | func (m *Mock) checkExpectation(call *Call) (bool, string) { |
| 652 | if !call.optional && !m.methodWasCalled(call.Method, call.Arguments) && call.totalCalls == 0 { |
| 653 | return false, fmt.Sprintf("FAIL:\t%s(%s)\n\t\tat: %s", call.Method, call.Arguments.String(), call.callerInfo) |
| 654 | } |
| 655 | if call.Repeatability > 0 { |
| 656 | return false, fmt.Sprintf("FAIL:\t%s(%s)\n\t\tat: %s", call.Method, call.Arguments.String(), call.callerInfo) |
| 657 | } |
| 658 | return true, fmt.Sprintf("PASS:\t%s(%s)", call.Method, call.Arguments.String()) |
| 659 | } |
| 660 | |
| 661 | // AssertNumberOfCalls asserts that the method was called expectedCalls times. |
| 662 | func (m *Mock) AssertNumberOfCalls(t TestingT, methodName string, expectedCalls int) bool { |
no test coverage detected