specta / expecta

A Matcher Framework for Objective-C/Cocoa
MIT License
1.59k stars 158 forks source link

Making respondTo matcher also checks if instance of classes also respondsToSelector: #184

Closed dchohfi closed 8 years ago

orta commented 8 years ago

Can you explain your thinking around this PR please?

dchohfi commented 8 years ago

hey @orta thank you for writing back.

just trying to be smart on the repondsTo matcher, as you guys do on EXPMatchers+equal, it checks for both pointer reference and equality.

for example: XCTAssertTrue([Foo instancesRespondToSelector:@selector(instanceMethod)]);

could be done with expect([Foo class]).respondsTo(@selector(instanceMethod));

orta commented 8 years ago

Alright - cool, lets do it