OCMockito v2.0.1 Release Notes
-
14 Oct 2015
Compatibility-breaking Change:
- ๐คก Eliminated
reset(mock)
sincereset
was likely to clash with mocked methods. CallstopMocking(mock)
instead.
๐ Fixes:
- ๐ Fixed crash when multiple mock objects are at play on multiple threads.
๐ Features:
- Stub void methods with
givenVoid(โฆ)
. Thanks to: Lysann Schlegel - Added
atMost(count)
forverifyCount()
. Thanks to: Emile Cantin
๐ Improvements:
- โ
Use
stopMocking(โฆ)
if a-dealloc
of your System Under Test is trying to message an object that is mocked. It disables message handling on the mock and frees its retained arguments. This prevents retain cycles and crashes during test clean-up. See StopMockingTests.m for an example. - NSInvocation+OCMockito.h is now imported by OCMockito.h, so it no longer needs a separate import.
๐ Deprecated:
- ๐ Deprecated MKTCapturingMatcher; use HCArgumentCaptor from OCHamcrest for capturing arguments. There is no need to call -capture to get a matcher to use as the argument, since HCArgumentCaptor is a matcher.
Project changes:
- โก๏ธ Updated project settings to Xcode 7, with tests now run by XCTest.
- ๐คก Eliminated