AssertNumberOfCalls: wrong order of arguments

The assert.Equal called had the actual and expected values mixed up.
This commit is contained in:
Boris Pruessmann 2015-07-03 13:30:03 +02:00
parent 089c7181b8
commit 84e2423404

View File

@ -352,7 +352,7 @@ func (m *Mock) AssertNumberOfCalls(t TestingT, methodName string, expectedCalls
actualCalls++
}
}
return assert.Equal(t, actualCalls, expectedCalls, fmt.Sprintf("Expected number of calls (%d) does not match the actual number of calls (%d).", expectedCalls, actualCalls))
return assert.Equal(t, expectedCalls, actualCalls, fmt.Sprintf("Expected number of calls (%d) does not match the actual number of calls (%d).", expectedCalls, actualCalls))
}
// AssertCalled asserts that the method was called.