-
Notifications
You must be signed in to change notification settings - Fork 140
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
RespondsTo matcher added #132
Conversation
Thank you for your contribution. Could you change the wording from responds_to to respond_to? Also, we prefer to use NSSelectorFromString() for non-existent selectors in our codebase, rather than ignoring the diagnostic. |
Ok, I will update this PR. |
@idoru, done. Could you review changes? |
Shouldn't it be a cstring instead of NSString to be similar to have_received and the like? |
@jeffh, that's make sense. What about third one method with cstring in addition to the existing methods? |
That works. — On Tue, Oct 29, 2013 at 12:52 PM, Alexey Denisov notifications@github.com
|
What do you mean? |
Good catch @jeffh. We should ensure both SEL and c-strings are supported (for consistency with HaveReceived). Supporting NSString would make it inconsistent with other method name matchers; The c-string format was provided as a short-hand, is there a reason why NSString would be useful? If so, we'll add it with a mind to support NSString elsewhere in future. If not, I think just SEL and c-strings are all we should support. |
@idoru, I got it. |
Great! Thanks for your contribution and being so flexible. |
You're welcome! |
With this matcher you're able to check if
class
orinstance
responds to some selector, via@selector
orNSString
, e.g.: