Is there some reason my Kiwi unit tests are failing with these two lines:
[[theValue([editAuthorViewController class] == [EditAuthorViewController class]) should] beYes];
[[theValue([editAuthorViewController isKindOfClass:[EditAuthorViewController class]]) should] beYes];
While this line passes?
NSString *classString = NSStringFromClass([editAuthorViewController class]);
[[classString should] equal:@"EditAuthorViewController"];
Turns out there's a Kiwi expression to test this I wasn't aware of.
This failed initially because my
EditAuthorViewController.m
file was added to my test target. Since[EditAuthorViewController class
] was returning a different pointer when called from inside the test bundle, the comparison failed.To fix this, I had to remove
EditAuthorViewController.m
from my Compile Sources in my test target.