标签: xcode sentestingkit
如果我为测试用例编写辅助方法:
- (void)testCallsHelper { [self helper]; // Can I get Xcode to highlight the failure here? } - (void)helper { STFail(@"Fail"); // Xcode highlights failure here }
这会很方便,因为使用Xcode突出显示可以更快地跳转到发生错误的位置,并且将重复的代码放入辅助方法也很方便。