From 8786303ef9b0460de66315317b7e497b23cedb7d Mon Sep 17 00:00:00 2001 From: Peter Friese Date: Wed, 26 Jul 2023 12:15:33 +0200 Subject: [PATCH 1/2] Fix compile errors in Combine This fixes compile errors that result from some method renamings in #11231 Signed-off-by: Peter Friese --- FirebaseCombineSwift/Tests/Unit/Auth/AuthMocks.swift | 7 ++++++- .../Tests/Unit/Auth/SignInWithGameCenterTests.swift | 2 +- .../Tests/Unit/FirebaseCombine-unit-Bridging-Header.h | 2 ++ 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/FirebaseCombineSwift/Tests/Unit/Auth/AuthMocks.swift b/FirebaseCombineSwift/Tests/Unit/Auth/AuthMocks.swift index 0a974e53858..a1df847b214 100644 --- a/FirebaseCombineSwift/Tests/Unit/Auth/AuthMocks.swift +++ b/FirebaseCombineSwift/Tests/Unit/Auth/AuthMocks.swift @@ -104,12 +104,17 @@ extension AuthBackendImplementationMock { fatalError("You need to implement \(#function) in your mock.") } + func getRecaptchaConfig(_ request: FIRGetRecaptchaConfigRequest, + callback: @escaping FIRGetRecaptchaConfigResponseCallback) { + fatalError("You need to implement \(#function) in your mock.") + } + func resetPassword(_ request: FIRResetPasswordRequest, callback: @escaping FIRResetPasswordCallback) { fatalError("You need to implement \(#function) in your mock.") } - func post(with request: FIRAuthRPCRequest, response: FIRAuthRPCResponse, + func call(with request: FIRAuthRPCRequest, response: FIRAuthRPCResponse, callback: @escaping (Error?) -> Void) { fatalError("You need to implement \(#function) in your mock.") } diff --git a/FirebaseCombineSwift/Tests/Unit/Auth/SignInWithGameCenterTests.swift b/FirebaseCombineSwift/Tests/Unit/Auth/SignInWithGameCenterTests.swift index eb206164ae4..b647ba4df5e 100644 --- a/FirebaseCombineSwift/Tests/Unit/Auth/SignInWithGameCenterTests.swift +++ b/FirebaseCombineSwift/Tests/Unit/Auth/SignInWithGameCenterTests.swift @@ -69,7 +69,7 @@ class SignInWithGameCenterTests: XCTestCase { var contentType: String? var handler: FIRAuthBackendRPCIssuerCompletionHandler? - func asyncPostToURL(with requestConfiguration: FIRAuthRequestConfiguration, url URL: URL, + func asyncCallToURL(with requestConfiguration: FIRAuthRequestConfiguration, url URL: URL, body: Data?, contentType: String, completionHandler handler: @escaping FIRAuthBackendRPCIssuerCompletionHandler) { requestURL = URL diff --git a/FirebaseCombineSwift/Tests/Unit/FirebaseCombine-unit-Bridging-Header.h b/FirebaseCombineSwift/Tests/Unit/FirebaseCombine-unit-Bridging-Header.h index 0d9d6e2feca..7a1b50b0ae7 100644 --- a/FirebaseCombineSwift/Tests/Unit/FirebaseCombine-unit-Bridging-Header.h +++ b/FirebaseCombineSwift/Tests/Unit/FirebaseCombine-unit-Bridging-Header.h @@ -66,6 +66,8 @@ #import "FirebaseAuth/Sources/Backend/RPC/FIRVerifyPasswordResponse.h" #import "FirebaseAuth/Sources/Backend/RPC/FIRVerifyPhoneNumberRequest.h" #import "FirebaseAuth/Sources/Backend/RPC/FIRVerifyPhoneNumberResponse.h" +#import "FirebaseAuth/Sources/Backend/RPC/FIRGetRecaptchaConfigRequest.h" +#import "FirebaseAuth/Sources/Backend/RPC/FIRGetRecaptchaConfigResponse.h" #import "FirebaseAuth/Sources/Utilities/FIRAuthErrorUtils.h" #import "FirebaseAuth/Sources/Utilities/FIRAuthURLPresenter.h" #import "FirebaseAuth/Sources/Utilities/FIRAuthWebUtils.h" From 0d3aa51cd17c1d0fd36c06ea3bdf7909149220b3 Mon Sep 17 00:00:00 2001 From: Peter Friese Date: Wed, 26 Jul 2023 12:28:19 +0200 Subject: [PATCH 2/2] Fix style Signed-off-by: Peter Friese --- .../Tests/Unit/FirebaseCombine-unit-Bridging-Header.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/FirebaseCombineSwift/Tests/Unit/FirebaseCombine-unit-Bridging-Header.h b/FirebaseCombineSwift/Tests/Unit/FirebaseCombine-unit-Bridging-Header.h index 7a1b50b0ae7..c413d6f7c36 100644 --- a/FirebaseCombineSwift/Tests/Unit/FirebaseCombine-unit-Bridging-Header.h +++ b/FirebaseCombineSwift/Tests/Unit/FirebaseCombine-unit-Bridging-Header.h @@ -42,6 +42,8 @@ #import "FirebaseAuth/Sources/Backend/RPC/FIRGetOOBConfirmationCodeResponse.h" #import "FirebaseAuth/Sources/Backend/RPC/FIRGetProjectConfigRequest.h" #import "FirebaseAuth/Sources/Backend/RPC/FIRGetProjectConfigResponse.h" +#import "FirebaseAuth/Sources/Backend/RPC/FIRGetRecaptchaConfigRequest.h" +#import "FirebaseAuth/Sources/Backend/RPC/FIRGetRecaptchaConfigResponse.h" #import "FirebaseAuth/Sources/Backend/RPC/FIRResetPasswordRequest.h" #import "FirebaseAuth/Sources/Backend/RPC/FIRResetPasswordResponse.h" #import "FirebaseAuth/Sources/Backend/RPC/FIRRevokeTokenRequest.h" @@ -66,8 +68,6 @@ #import "FirebaseAuth/Sources/Backend/RPC/FIRVerifyPasswordResponse.h" #import "FirebaseAuth/Sources/Backend/RPC/FIRVerifyPhoneNumberRequest.h" #import "FirebaseAuth/Sources/Backend/RPC/FIRVerifyPhoneNumberResponse.h" -#import "FirebaseAuth/Sources/Backend/RPC/FIRGetRecaptchaConfigRequest.h" -#import "FirebaseAuth/Sources/Backend/RPC/FIRGetRecaptchaConfigResponse.h" #import "FirebaseAuth/Sources/Utilities/FIRAuthErrorUtils.h" #import "FirebaseAuth/Sources/Utilities/FIRAuthURLPresenter.h" #import "FirebaseAuth/Sources/Utilities/FIRAuthWebUtils.h"