Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions GoogleSignIn/Tests/Unit/GIDSignInTest.m
Original file line number Diff line number Diff line change
Expand Up @@ -321,18 +321,20 @@ - (void)setUp {
});
_user = OCMStrictClassMock([GIDGoogleUser class]);
_oidAuthorizationService = OCMStrictClassMock([OIDAuthorizationService class]);
OCMStub([_oidAuthorizationService
// AppAuth 3.1.0 has instance methods with these selectors. Without ClassMethod(), OCMock
// stubs the instance methods, and these stubs never run.
OCMStub(ClassMethod([_oidAuthorizationService
presentAuthorizationRequest:SAVE_TO_ARG_BLOCK(self->_savedAuthorizationRequest)
#if TARGET_OS_IOS || TARGET_OS_MACCATALYST
presentingViewController:SAVE_TO_ARG_BLOCK(self->_savedPresentingViewController)
#elif TARGET_OS_OSX
presentingWindow:SAVE_TO_ARG_BLOCK(self->_savedPresentingWindow)
#endif // TARGET_OS_IOS || TARGET_OS_MACCATALYST
callback:COPY_TO_ARG_BLOCK(self->_savedAuthorizationCallback)]);
OCMStub([self->_oidAuthorizationService
callback:COPY_TO_ARG_BLOCK(self->_savedAuthorizationCallback)]));
OCMStub(ClassMethod([self->_oidAuthorizationService
performTokenRequest:SAVE_TO_ARG_BLOCK(self->_savedTokenRequest)
originalAuthorizationResponse:[OCMArg any]
callback:COPY_TO_ARG_BLOCK(self->_savedTokenCallback)]);
callback:COPY_TO_ARG_BLOCK(self->_savedTokenCallback)]));

// Fakes
_authStateMigrationService = [[GIDFakeAuthStateMigration alloc] init];
Expand Down
Loading