Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何对给定按钮内部的触摸等事件进行单元测试是否会调用特定的segue?我知道我可以直接调用 segue 并检查结果,但我想测试事件是否会执行 segue,换句话说,故事板中的链接是否正常。
我不知道这是否是您的疑问,但您可以检查这是否正确 segue
尝试这个:
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender { if ([[segue identifier] isEqualToString:@"YOUR_SEGUE_NAME_HERE"]) { } }
所以我决定开始用 C# 编程,我做的一件事是创建一个“pausec.exe”(pause.exe 克隆)。它可以工作,但是当像这样调用它时:
< nul pausec
……它崩溃了。我得到的错误——据我所知从西班牙语翻译成——是这样的:
未处理的异常:System.I