-
Notifications
You must be signed in to change notification settings - Fork 606
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OCMObserverMockObject doesn't have a reject method #114
Comments
Observer mocks are meant to be strict (as mentioned in http://ocmock.org/reference/#observer-mocks). Is that not the case? Does the observer receive an unexpected notification and not complain? That would be a bug. |
Ah, I missed that. Guess I need to have more caffeine before reading documentation. |
Partly my fault, too. The design isn't very symmetric. In the new syntax class mocks, partial mocks, and protocol mocks are all created "nice" by default while observer mocks are strict by default. In hindsight I don't know how I end up there. |
sry for re-using this issue, but how do I implement rejecting a specific notification I don't want to receive? |
I have some code which should only post a notification under certain circumstances. While observer mocks work great for testing if a notification was posted, they don't work for testing that a notification wasn't sent as they lack a -reject method.
The text was updated successfully, but these errors were encountered: