UIテスト
何々ができるまで待つ
XCUIApplication *app = [[XCUIApplication alloc] init]; NSPredicate *existsPredicate = [NSPredicate predicateWithBlock:^BOOL(XCUIElement *app, NSDictionary<NSString *,id> * _Nullable bindings) { if (app.buttons[@"hoge"]) return YES; return NO; }]; [self expectationForPredicate:existsPredicate evaluatedWithObject:app handler:nil];