#1122·mockery

Type safe wrapper for AssertNotCalled()

Author: iceberg901Created Nov 9, 2025Updated Nov 9, 2025

In just the way that the EXPECT() interface adds a typesafe wrapper for On, I'd like to add a type safe wrapper for AssertNotCalled.

Then, one could write code something like

mock.ASSERT(t).NotCalled().MethodName(mock.Anything, mock.Anything)

which would be implemented internally as

mock.AssertNotCalled(t, "MethodName", mock.Anything, mock.Anything)

Would you consider accepting such functionality?