|
@@ -228,23 +228,9 @@ static NSString *const kNewScope = @"newScope";
|
|
|
// The configuration to be used when testing `GIDSignIn`.
|
|
// The configuration to be used when testing `GIDSignIn`.
|
|
|
GIDConfiguration *_configuration;
|
|
GIDConfiguration *_configuration;
|
|
|
|
|
|
|
|
- // The login hint to be used when testing `GIDSignIn`.
|
|
|
|
|
- NSString *_hint;
|
|
|
|
|
-
|
|
|
|
|
// The completion to be used when testing `GIDSignIn`.
|
|
// The completion to be used when testing `GIDSignIn`.
|
|
|
GIDSignInCompletion _completion;
|
|
GIDSignInCompletion _completion;
|
|
|
|
|
|
|
|
-#if TARGET_OS_IOS || TARGET_OS_MACCATALYST
|
|
|
|
|
- // The saved presentingViewController from the authorization request.
|
|
|
|
|
- UIViewController *_savedPresentingViewController;
|
|
|
|
|
-#elif TARGET_OS_OSX
|
|
|
|
|
- // The saved presentingWindow from the authorization request.
|
|
|
|
|
- NSWindow *_savedPresentingWindow;
|
|
|
|
|
-#endif // TARGET_OS_IOS || TARGET_OS_MACCATALYST
|
|
|
|
|
-
|
|
|
|
|
- // The saved authorization callback.
|
|
|
|
|
- OIDAuthorizationCallback _savedAuthorizationCallback;
|
|
|
|
|
-
|
|
|
|
|
// The saved token request.
|
|
// The saved token request.
|
|
|
OIDTokenRequest *_savedTokenRequest;
|
|
OIDTokenRequest *_savedTokenRequest;
|
|
|
|
|
|
|
@@ -308,8 +294,6 @@ static NSString *const kNewScope = @"newScope";
|
|
|
profileDataFetcher:_profileDataFetcher
|
|
profileDataFetcher:_profileDataFetcher
|
|
|
authorizationFlowProcessor:_authorizationFlowProcessor];
|
|
authorizationFlowProcessor:_authorizationFlowProcessor];
|
|
|
|
|
|
|
|
- _hint = nil;
|
|
|
|
|
-
|
|
|
|
|
__weak GIDSignInTest *weakSelf = self;
|
|
__weak GIDSignInTest *weakSelf = self;
|
|
|
_completion = ^(GIDSignInResult *_Nullable signInResult, NSError * _Nullable error) {
|
|
_completion = ^(GIDSignInResult *_Nullable signInResult, NSError * _Nullable error) {
|
|
|
GIDSignInTest *strongSelf = weakSelf;
|
|
GIDSignInTest *strongSelf = weakSelf;
|
|
@@ -772,7 +756,7 @@ static NSString *const kNewScope = @"newScope";
|
|
|
#elif TARGET_OS_OSX
|
|
#elif TARGET_OS_OSX
|
|
|
XCTAssertThrows([_signIn signInWithPresentingWindow:_presentingWindow
|
|
XCTAssertThrows([_signIn signInWithPresentingWindow:_presentingWindow
|
|
|
#endif // TARGET_OS_IOS || TARGET_OS_MACCATALYST
|
|
#endif // TARGET_OS_IOS || TARGET_OS_MACCATALYST
|
|
|
- hint:_hint
|
|
|
|
|
|
|
+ hint:nil
|
|
|
completion:_completion]);
|
|
completion:_completion]);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -807,7 +791,7 @@ static NSString *const kNewScope = @"newScope";
|
|
|
#elif TARGET_OS_OSX
|
|
#elif TARGET_OS_OSX
|
|
|
[_signIn signInWithPresentingWindow:_presentingWindow
|
|
[_signIn signInWithPresentingWindow:_presentingWindow
|
|
|
#endif // TARGET_OS_IOS || TARGET_OS_MACCATALYST
|
|
#endif // TARGET_OS_IOS || TARGET_OS_MACCATALYST
|
|
|
- hint:_hint
|
|
|
|
|
|
|
+ hint:nil
|
|
|
completion:_completion];
|
|
completion:_completion];
|
|
|
} @catch (NSException *exception) {
|
|
} @catch (NSException *exception) {
|
|
|
threw = YES;
|
|
threw = YES;
|
|
@@ -1107,7 +1091,7 @@ static NSString *const kNewScope = @"newScope";
|
|
|
#elif TARGET_OS_OSX
|
|
#elif TARGET_OS_OSX
|
|
|
[_signIn signInWithPresentingWindow:_presentingWindow
|
|
[_signIn signInWithPresentingWindow:_presentingWindow
|
|
|
#endif // TARGET_OS_IOS || TARGET_OS_MACCATALYST
|
|
#endif // TARGET_OS_IOS || TARGET_OS_MACCATALYST
|
|
|
- hint:_hint
|
|
|
|
|
|
|
+ hint:nil
|
|
|
completion:completion];
|
|
completion:completion];
|
|
|
}
|
|
}
|
|
|
|
|
|