iOS开发技巧之:跳转到TestFlight

有的时候我们的应用可能需要上TestFlight,这个时候升级就需要跳到TestFlight里面。方法如下:

- (void)jumpTestFlight {
    NSString *urlString = @"beta.itunes.apple.com/v1/app/AppleID";
    if ([[UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"itms-beta://"]]) {
        urlString = [NSString stringWithFormat:@"itms-beta://%@",urlString];
        NSURL *url = [NSURL URLWithString:urlString];
        [[UIApplication sharedApplication] openURL:url];
    }else{
        urlString = [NSString stringWithFormat:@"https://%@",urlString];
        NSURL*url = [NSURL URLWithString:urlString];
        [[UIApplication sharedApplication] openURL:url];
    }
}
https://testflightapple.co/tf/xxxxxxxxxxx
https://testflight.apple.com/join/xxxxxxx

你可能感兴趣的:(iOS开发技巧之:跳转到TestFlight)