erikdoe / ocmock

Mock objects for Objective-C
http://ocmock.org
Apache License 2.0
2.16k stars 606 forks source link

Stop retaining class objects in invocations #412

Closed dmaclach closed 4 years ago

dmaclach commented 4 years ago

Fix for https://github.com/erikdoe/ocmock/issues/411

dmaclach commented 4 years ago

This is required to allow https://github.com/TextureGroup/Texture to be able to be moved over to OCMock 3.6.

erikdoe commented 4 years ago

Looking at #418 I released that the same behaviour usually applies to arguments and return values, which is why in #418 the change is made in both places.

In this PR the change was only made for arguments. Would it make sense to explore whether it should also apply to the return value?

dmaclach commented 4 years ago

I would actually like to kill the return value branch of the logic entirely since it is never used. The return value is always nil coming through here. None of the return value branch is tested at all using the test suite.