Quellcode durchsuchen

Updated to SwiftFormat 0.52.10 (#12125)

Paul Beusterien vor 2 Jahren
Ursprung
Commit
4d2b60dc75
100 geänderte Dateien mit 177 neuen und 181 gelöschten Zeilen
  1. 1 1
      ClientApp/Shared-iOS11+/swift-import-test.swift
  2. 1 1
      CoreOnly/Tests/FirebasePodTest/FirebasePodTest/AppDelegate.swift
  3. 1 1
      Example/CombineSample/CombineSample/App/CombineSampleApp.swift
  4. 2 2
      Example/CombineSample/CombineSample/ViewModels/Authentication/AnonymousSignInViewModel.swift
  5. 1 1
      Example/CombineSample/CombineSample/ViewModels/Authentication/UserInfoViewModel.swift
  6. 2 2
      Example/CombineSample/CombineSample/Views/Authentication/AnonymousSignInView.swift
  7. 2 2
      Example/FirestoreSample/FirestoreSample/App/FirestoreSampleApp.swift
  8. 1 1
      Example/FirestoreSample/FirestoreSample/Views/FavouriteFruitsAnimationView.swift
  9. 1 1
      Example/FirestoreSample/FirestoreSample/Views/FavouriteFruitsMappingErrorView.swift
  10. 1 1
      Example/FirestoreSample/FirestoreSample/Views/FavouriteFruitsMappingErrorView2.swift
  11. 1 1
      Example/FirestoreSample/FirestoreSample/Views/FavouriteFruitsNoAnimationsView.swift
  12. 1 1
      Example/FirestoreSample/FirestoreSample/Views/FavouriteFruitsView.swift
  13. 1 1
      Example/tvOSSample/tvOSSample/AppDelegate.swift
  14. 1 1
      Example/tvOSSample/tvOSSample/AuthLoginViewController.swift
  15. 1 1
      Example/tvOSSample/tvOSSample/AuthViewController.swift
  16. 1 1
      Example/tvOSSample/tvOSSample/DatabaseViewController.swift
  17. 1 1
      Example/tvOSSample/tvOSSample/EmailLoginViewController.swift
  18. 1 1
      Example/tvOSSample/tvOSSample/StorageViewController.swift
  19. 1 1
      Example/watchOSSample/SampleWatchAppWatchKitExtension/InterfaceController.swift
  20. 1 1
      Example/watchOSSample/SampleWatchAppWatchKitExtension/NotificationController.swift
  21. 1 1
      Example/watchOSSample/ServiceExtension/NotificationService.swift
  22. 1 1
      FirebaseABTesting/Tests/Integration/ABTQA/AppDelegate.swift
  23. 1 1
      FirebaseABTesting/Tests/Integration/ABTQA/ViewController.swift
  24. 1 1
      FirebaseAnalytics/Analytics+SwiftUI.swift
  25. 1 1
      FirebaseAnalyticsSwift/Tests/SwiftUnit/AnalyticsAPITests.swift
  26. 2 2
      FirebaseAppCheck/Apps/AppCheckCustomProvideApp/AppCheckCustomProvideApp/AppDelegate.swift
  27. 2 2
      FirebaseAppCheck/Apps/AppCheckCustomProvideApp/AppCheckCustomProvideApp/MyAppCheckProvider.swift
  28. 1 1
      FirebaseAppCheck/Apps/AppCheckCustomProvideApp/AppCheckCustomProvideApp/SceneDelegate.swift
  29. 1 1
      FirebaseAppCheck/Apps/FIRAppCheckTestApp/FIRAppCheckTestApp/AppDelegate.swift
  30. 1 1
      FirebaseAppCheck/Tests/Unit/Swift/AppCheckAPITests.swift
  31. 1 1
      FirebaseAppDistribution/Tests/Unit/Swift/AppDistributionAPITest.swift
  32. 2 2
      FirebaseAppDistributionInternal/Sources/ApiService.swift
  33. 1 1
      FirebaseAppDistributionInternal/Sources/InAppFeedback.swift
  34. 2 2
      FirebaseAppDistributionInternal/Sources/Internal/InstallationsProtocol.swift
  35. 2 2
      FirebaseAppDistributionInternal/Tests/Unit/ApiServiceTests.swift
  36. 2 2
      FirebaseAppDistributionInternal/Tests/Unit/FakeUtils/FakeInstallations.swift
  37. 1 1
      FirebaseAuth/Tests/Sample/SwiftApiTests/AccountInfoTests.swift
  38. 1 1
      FirebaseAuth/Tests/Sample/SwiftApiTests/AnonymousTests.swift
  39. 1 1
      FirebaseAuth/Tests/Sample/SwiftApiTests/Credentials.swift
  40. 1 1
      FirebaseAuth/Tests/Sample/SwiftApiTests/EmailPasswordTests.swift
  41. 1 1
      FirebaseAuth/Tests/Sample/SwiftApiTests/FacebookTests.swift
  42. 1 1
      FirebaseAuth/Tests/Sample/SwiftApiTests/GoogleTests.swift
  43. 1 1
      FirebaseAuth/Tests/Sample/SwiftApiTests/TestsBase.swift
  44. 1 1
      FirebaseCombineSwift/Sources/Core/Core.swift
  45. 1 1
      FirebaseCombineSwift/Sources/Storage/StorageReference+Combine.swift
  46. 1 1
      FirebaseCombineSwift/Tests/Integration/Storage/StorageIntegration.swift
  47. 2 2
      FirebaseCombineSwift/Tests/Unit/Auth/AnonymousAuthTests.swift
  48. 1 1
      FirebaseCombineSwift/Tests/Unit/Auth/AuthMocks.swift
  49. 3 3
      FirebaseCombineSwift/Tests/Unit/Auth/AuthStateDidChangePublisherTests.swift
  50. 2 2
      FirebaseCombineSwift/Tests/Unit/Auth/EmailLinkAuthTests.swift
  51. 2 2
      FirebaseCombineSwift/Tests/Unit/Auth/EmailPasswordAuthTests.swift
  52. 2 2
      FirebaseCombineSwift/Tests/Unit/Auth/FetchSignInMethodsTests.swift
  53. 2 2
      FirebaseCombineSwift/Tests/Unit/Auth/GameCenterAuthProviderTests.swift
  54. 3 3
      FirebaseCombineSwift/Tests/Unit/Auth/IDTokenDidChangePublisherTests.swift
  55. 2 2
      FirebaseCombineSwift/Tests/Unit/Auth/OAuthProviderTests.swift
  56. 2 2
      FirebaseCombineSwift/Tests/Unit/Auth/PasswordResetTests.swift
  57. 2 2
      FirebaseCombineSwift/Tests/Unit/Auth/PhoneAuthProviderTests.swift
  58. 8 10
      FirebaseCombineSwift/Tests/Unit/Auth/SignInWithCredentialTests.swift
  59. 2 2
      FirebaseCombineSwift/Tests/Unit/Auth/SignInWithCustomTokenTests.swift
  60. 2 2
      FirebaseCombineSwift/Tests/Unit/Auth/SignInWithGameCenterTests.swift
  61. 2 2
      FirebaseCombineSwift/Tests/Unit/Auth/SignInWithProviderTests.swift
  62. 2 2
      FirebaseCombineSwift/Tests/Unit/Auth/UpdateCurrentUserTests.swift
  63. 8 10
      FirebaseCombineSwift/Tests/Unit/Auth/UserTests.swift
  64. 2 2
      FirebaseCombineSwift/Tests/Unit/AuthBackend+Combine.swift
  65. 1 1
      FirebaseCombineSwift/Tests/Unit/FirebaseApp+Tests.swift
  66. 2 2
      FirebaseCombineSwift/Tests/Unit/Firestore/GetDocumentsTests.swift
  67. 2 2
      FirebaseCombineSwift/Tests/Unit/Storage/StorageReferenceTests.swift
  68. 1 1
      FirebaseCore/Internal/Tests/Common/Assertions.swift
  69. 1 1
      FirebaseCore/Internal/Tests/Integration/HeartbeatLoggingIntegrationTests.swift
  70. 1 1
      FirebaseCore/Internal/Tests/Unit/HeartbeatControllerTests.swift
  71. 1 1
      FirebaseCore/Internal/Tests/Unit/HeartbeatStorageTests.swift
  72. 1 1
      FirebaseCore/Internal/Tests/Unit/HeartbeatTests.swift
  73. 1 1
      FirebaseCore/Internal/Tests/Unit/HeartbeatsBundleTests.swift
  74. 1 1
      FirebaseCore/Internal/Tests/Unit/HeartbeatsPayloadTests.swift
  75. 1 1
      FirebaseCore/Internal/Tests/Unit/RingBufferTests.swift
  76. 1 1
      FirebaseCore/Internal/Tests/Unit/StorageTests.swift
  77. 1 1
      FirebaseCore/Internal/Tests/Unit/WeakContainerTests.swift
  78. 1 1
      FirebaseCore/Tests/SwiftUnit/FirebaseAppTests.swift
  79. 1 1
      FirebaseCore/Tests/SwiftUnit/FirebaseConfigurationTests.swift
  80. 1 1
      FirebaseCore/Tests/SwiftUnit/FirebaseOptionsTests.swift
  81. 1 1
      FirebaseFunctions/Sources/Callable+Codable.swift
  82. 25 25
      FirebaseFunctions/Sources/Functions.swift
  83. 4 4
      FirebaseFunctions/Sources/FunctionsError.swift
  84. 3 3
      FirebaseFunctions/Sources/HTTPSCallable.swift
  85. 1 1
      FirebaseFunctions/Sources/Internal/FunctionsComponent.swift
  86. 5 5
      FirebaseFunctions/Sources/Internal/FunctionsContext.swift
  87. 2 2
      FirebaseFunctions/Sources/Internal/FunctionsSerializer.swift
  88. 2 2
      FirebaseFunctions/Tests/CombineUnit/HTTPSCallableTests.swift
  89. 1 1
      FirebaseFunctions/Tests/Integration/IntegrationTests.swift
  90. 1 1
      FirebaseFunctions/Tests/Unit/FunctionsTests.swift
  91. 1 1
      FirebaseInAppMessaging/Swift/Tests/Integration/FIAMSwiftUI/Shared/ContentView.swift
  92. 1 1
      FirebaseInAppMessaging/Swift/Tests/Integration/FIAMSwiftUI/Shared/ModalInAppMessageView.swift
  93. 1 1
      FirebaseMLModelDownloader/Apps/Sample/MLDownloaderTestApp/AppDelegate.swift
  94. 1 1
      FirebaseMLModelDownloader/Apps/Sample/MLDownloaderTestApp/ContentView.swift
  95. 1 1
      FirebaseMLModelDownloader/Apps/Sample/MLDownloaderTestApp/Downloader.swift
  96. 1 1
      FirebaseMLModelDownloader/Apps/Sample/MLDownloaderTestApp/SceneDelegate.swift
  97. 1 1
      FirebaseMLModelDownloader/Sources/ModelDownloader.swift
  98. 1 1
      FirebaseMLModelDownloader/Sources/ModelInfoRetriever.swift
  99. 1 1
      FirebaseMLModelDownloader/Sources/TelemetryLogger.swift
  100. 1 1
      FirebaseMLModelDownloader/Tests/Integration/ModelDownloaderIntegrationTests.swift

+ 1 - 1
ClientApp/Shared-iOS11+/swift-import-test.swift

@@ -49,8 +49,8 @@ import FirebaseInstallations
 import FirebaseMessaging
 import FirebaseMLModelDownloader
 #if (os(iOS) && !targetEnvironment(macCatalyst)) || os(tvOS)
-  import FirebasePerformance
   import FirebaseInAppMessaging
+  import FirebasePerformance
 #endif
 import FirebaseRemoteConfig
 import FirebaseRemoteConfigSwift

+ 1 - 1
CoreOnly/Tests/FirebasePodTest/FirebasePodTest/AppDelegate.swift

@@ -12,12 +12,12 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import UIKit
 import Firebase
 // Verify that the following Firebase Swift APIs can be found.
 import FirebaseAnalyticsSwift
 import FirebaseFirestoreSwift
 import FirebaseInAppMessagingSwift
+import UIKit
 
 class CoreExists: FirebaseApp {}
 class AnalyticsExists: Analytics {}

+ 1 - 1
Example/CombineSample/CombineSample/App/CombineSampleApp.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import SwiftUI
 import Firebase
+import SwiftUI
 
 @main
 struct CombineSampleApp: App {

+ 2 - 2
Example/CombineSample/CombineSample/ViewModels/Authentication/AnonymousSignInViewModel.swift

@@ -12,13 +12,13 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
+import Combine
 import Firebase
 import FirebaseAuthCombineSwift
 import FirebaseFirestoreCombineSwift
 import FirebaseFunctionsCombineSwift
 import FirebaseStorageCombineSwift
-import Combine
+import Foundation
 
 class AnonymousSignInViewModel: UserInfoViewModel {
   private var cancellables = Set<AnyCancellable>()

+ 1 - 1
Example/CombineSample/CombineSample/ViewModels/Authentication/UserInfoViewModel.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
+import Combine
 import Firebase
 import FirebaseAuth
 import FirebaseAuthCombineSwift
-import Combine
 
 class UserInfoViewModel: ObservableObject {
   @Published var user: User?

+ 2 - 2
Example/CombineSample/CombineSample/Views/Authentication/AnonymousSignInView.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import SwiftUI
+import Combine
 import Firebase
 import FirebaseAuthCombineSwift
-import Combine
+import SwiftUI
 
 struct AnonymousSignInView: View {
   @StateObject var viewModel = AnonymousSignInViewModel()

+ 2 - 2
Example/FirestoreSample/FirestoreSample/App/FirestoreSampleApp.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import SwiftUI
+import FirebaseAuth
 import FirebaseCore
 import FirebaseFirestore
-import FirebaseAuth
+import SwiftUI
 
 class AppDelegate: NSObject, UIApplicationDelegate {
   func application(_ application: UIApplication,

+ 1 - 1
Example/FirestoreSample/FirestoreSample/Views/FavouriteFruitsAnimationView.swift

@@ -12,9 +12,9 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import SwiftUI
 import FirebaseFirestore
 import FirebaseFirestoreSwift
+import SwiftUI
 
 private struct Fruit: Codable, Identifiable, Equatable {
   @DocumentID var id: String?

+ 1 - 1
Example/FirestoreSample/FirestoreSample/Views/FavouriteFruitsMappingErrorView.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import SwiftUI
 import FirebaseFirestoreSwift
+import SwiftUI
 
 private struct Fruit: Codable, Identifiable, Equatable {
   @DocumentID var id: String?

+ 1 - 1
Example/FirestoreSample/FirestoreSample/Views/FavouriteFruitsMappingErrorView2.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import SwiftUI
 import FirebaseFirestoreSwift
+import SwiftUI
 
 private struct Fruit: Codable, Identifiable, Equatable {
   @DocumentID var id: String?

+ 1 - 1
Example/FirestoreSample/FirestoreSample/Views/FavouriteFruitsNoAnimationsView.swift

@@ -12,9 +12,9 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import SwiftUI
 import FirebaseFirestore
 import FirebaseFirestoreSwift
+import SwiftUI
 
 private struct Fruit: Codable, Identifiable, Equatable {
   @DocumentID var id: String?

+ 1 - 1
Example/FirestoreSample/FirestoreSample/Views/FavouriteFruitsView.swift

@@ -12,9 +12,9 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import SwiftUI
 import FirebaseFirestore
 import FirebaseFirestoreSwift
+import SwiftUI
 
 private struct Fruit: Codable, Identifiable, Equatable {
   @DocumentID var id: String?

+ 1 - 1
Example/tvOSSample/tvOSSample/AppDelegate.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import UIKit
 import FirebaseCore
+import UIKit
 
 @UIApplicationMain
 class AppDelegate: UIResponder, UIApplicationDelegate {

+ 1 - 1
Example/tvOSSample/tvOSSample/AuthLoginViewController.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import UIKit
 import FirebaseAuth
+import UIKit
 
 class AuthLoginViewController: UIViewController {
   override func viewDidLoad() {

+ 1 - 1
Example/tvOSSample/tvOSSample/AuthViewController.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import UIKit
 import FirebaseAuth
+import UIKit
 
 class AuthViewController: UIViewController {
   // MARK: - User Interface

+ 1 - 1
Example/tvOSSample/tvOSSample/DatabaseViewController.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import UIKit
 import FirebaseDatabase
+import UIKit
 
 /// A class to demonstrate the Firebase Realtime Database API. This will show a number read
 /// from the Database and increase or decrease it based on the buttons pressed.

+ 1 - 1
Example/tvOSSample/tvOSSample/EmailLoginViewController.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import UIKit
 import FirebaseAuth
+import UIKit
 
 protocol EmailLoginDelegate {
   func emailLogin(_ controller: EmailLoginViewController, signedInAs user: User)

+ 1 - 1
Example/tvOSSample/tvOSSample/StorageViewController.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import UIKit
 import FirebaseStorage
+import UIKit
 
 class StorageViewController: UIViewController {
   /// An enum describing the different states of the view controller.

+ 1 - 1
Example/watchOSSample/SampleWatchAppWatchKitExtension/InterfaceController.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import SwiftUI
 import FirebaseStorage
+import SwiftUI
 
 class InterfaceController: WKInterfaceController {
   @IBOutlet var imageView: WKInterfaceImage!

+ 1 - 1
Example/watchOSSample/SampleWatchAppWatchKitExtension/NotificationController.swift

@@ -12,9 +12,9 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import WatchKit
 import Foundation
 import UserNotifications
+import WatchKit
 
 class NotificationController: WKUserNotificationInterfaceController {
   override init() {

+ 1 - 1
Example/watchOSSample/ServiceExtension/NotificationService.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import UserNotifications
 import FirebaseMessaging
+import UserNotifications
 
 class NotificationService: UNNotificationServiceExtension {
   var contentHandler: ((UNNotificationContent) -> Void)?

+ 1 - 1
FirebaseABTesting/Tests/Integration/ABTQA/AppDelegate.swift

@@ -14,8 +14,8 @@
  * limitations under the License.
  */
 
-import UIKit
 import Firebase
+import UIKit
 
 @UIApplicationMain
 class AppDelegate: UIResponder, UIApplicationDelegate {

+ 1 - 1
FirebaseABTesting/Tests/Integration/ABTQA/ViewController.swift

@@ -14,9 +14,9 @@
  * limitations under the License.
  */
 
-import UIKit
 import FirebaseAnalytics
 import FirebaseRemoteConfig
+import UIKit
 
 class ViewController: UIViewController {
   @IBAction func fireAnalyticsEventButtonTapped(_ sender: Any) {

+ 1 - 1
FirebaseAnalytics/Analytics+SwiftUI.swift

@@ -19,7 +19,7 @@
   /// Custom view modifier to allow for easily logging screen view events.
   @available(iOS 13.0, macOS 10.15, macCatalyst 13.0, tvOS 13.0, *)
   @available(watchOS, unavailable)
-  internal struct LoggedAnalyticsModifier: ViewModifier {
+  struct LoggedAnalyticsModifier: ViewModifier {
     /// The name of the view to log in the `AnalyticsParameterScreenName` parameter.
     let screenName: String
 

+ 1 - 1
FirebaseAnalyticsSwift/Tests/SwiftUnit/AnalyticsAPITests.swift

@@ -20,9 +20,9 @@ import Foundation
 import StoreKit
 import SwiftUI
 
+import FirebaseAnalytics
 import FirebaseAnalyticsSwift
 import SwiftUI
-import FirebaseAnalytics
 
 final class AnalyticsAPITests {
   func usage() {

+ 2 - 2
FirebaseAppCheck/Apps/AppCheckCustomProvideApp/AppCheckCustomProvideApp/AppDelegate.swift

@@ -14,9 +14,9 @@
  * limitations under the License.
  */
 
-import UIKit
-import FirebaseCore
 import FirebaseAppCheck
+import FirebaseCore
+import UIKit
 
 @main
 class AppDelegate: UIResponder, UIApplicationDelegate {

+ 2 - 2
FirebaseAppCheck/Apps/AppCheckCustomProvideApp/AppCheckCustomProvideApp/MyAppCheckProvider.swift

@@ -14,9 +14,9 @@
  * limitations under the License.
  */
 
-import Foundation
-import FirebaseCore
 import FirebaseAppCheck
+import FirebaseCore
+import Foundation
 
 class MyAppCheckProvider: NSObject, AppCheckProvider {
   func getToken(completion handler: @escaping AppCheckTokenHandler) {

+ 1 - 1
FirebaseAppCheck/Apps/AppCheckCustomProvideApp/AppCheckCustomProvideApp/SceneDelegate.swift

@@ -14,8 +14,8 @@
  * limitations under the License.
  */
 
-import UIKit
 import SwiftUI
+import UIKit
 
 class SceneDelegate: UIResponder, UIWindowSceneDelegate {
   var window: UIWindow?

+ 1 - 1
FirebaseAppCheck/Apps/FIRAppCheckTestApp/FIRAppCheckTestApp/AppDelegate.swift

@@ -16,8 +16,8 @@
 
 import UIKit
 
-import FirebaseCore
 import FirebaseAppCheck
+import FirebaseCore
 
 @main
 class AppDelegate: UIResponder, UIApplicationDelegate {

+ 1 - 1
FirebaseAppCheck/Tests/Unit/Swift/AppCheckAPITests.swift

@@ -18,8 +18,8 @@
 
 import Foundation
 
-import FirebaseCore
 import FirebaseAppCheck
+import FirebaseCore
 
 final class AppCheckAPITests {
   func usage() {

+ 1 - 1
FirebaseAppDistribution/Tests/Unit/Swift/AppDistributionAPITest.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseAppDistribution
+import XCTest
 
 class AppDistributionAPITests: XCTestCase {
   @available(iOS 13.0.0, *)

+ 2 - 2
FirebaseAppDistributionInternal/Sources/ApiService.swift

@@ -12,9 +12,9 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
-import FirebaseInstallations
 import FirebaseCore
+import FirebaseInstallations
+import Foundation
 import UIKit
 
 // Avoids exposing internal APIs to Swift users

+ 1 - 1
FirebaseAppDistributionInternal/Sources/InAppFeedback.swift

@@ -13,8 +13,8 @@
 // limitations under the License.
 
 import Foundation
-import UIKit
 import Photos
+import UIKit
 
 @objc(FIRFADInAppFeedback) open class InAppFeedback: NSObject {
   @objc(

+ 2 - 2
FirebaseAppDistributionInternal/Sources/Internal/InstallationsProtocol.swift

@@ -12,12 +12,12 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import FirebaseInstallations
+import Foundation
 
 // Wraps around the use of FIRInstallations in a protocol to be able to inject a fake one for
 // unit testing.
-internal protocol InstallationsProtocol {
+protocol InstallationsProtocol {
   func authToken(completion: @escaping (InstallationsAuthTokenResult?, Error?) -> Void)
   func installationID(completion: @escaping (String?, Error?) -> Void)
 }

+ 2 - 2
FirebaseAppDistributionInternal/Tests/Unit/ApiServiceTests.swift

@@ -12,11 +12,11 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 import FirebaseCore
+import XCTest
 
-@testable import FirebaseInstallations
 @testable import FirebaseAppDistributionInternal
+@testable import FirebaseInstallations
 
 class ApiServiceTests: XCTestCase {
   override class func setUp() {

+ 2 - 2
FirebaseAppDistributionInternal/Tests/Unit/FakeUtils/FakeInstallations.swift

@@ -12,9 +12,9 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
-@testable import FirebaseInstallations
 @testable import FirebaseAppDistributionInternal
+@testable import FirebaseInstallations
+import Foundation
 
 // This is needed because importing the setter from FIRInstallationsAuthTokenResultInternal.h in
 // the bridging error results in errors.

+ 1 - 1
FirebaseAuth/Tests/Sample/SwiftApiTests/AccountInfoTests.swift

@@ -14,8 +14,8 @@
  * limitations under the License.
  */
 
-import XCTest
 import FirebaseAuth
+import XCTest
 
 class AccountInfoTests: TestsBase {
   /** The testing email address for testCreateAccountWithEmailAndPassword. */

+ 1 - 1
FirebaseAuth/Tests/Sample/SwiftApiTests/AnonymousTests.swift

@@ -14,8 +14,8 @@
  * limitations under the License.
  */
 
-import Foundation
 import FirebaseAuth
+import Foundation
 import XCTest
 
 class AnonymousTests: TestsBase {

+ 1 - 1
FirebaseAuth/Tests/Sample/SwiftApiTests/Credentials.swift

@@ -48,7 +48,7 @@ import Foundation
  The name of the test user for Facebook Login.
  */
 
-class Credentials {
+enum Credentials {
   static let kGoogleClientID = KGOOGLE_CLIENT_ID
   static let kGoogleTestAccountRefreshToken = KGOOGLE_TEST_ACCOUNT_REFRESH_TOKEN
   static let kGoogleUserName = KGOOGLE_USER_NAME

+ 1 - 1
FirebaseAuth/Tests/Sample/SwiftApiTests/EmailPasswordTests.swift

@@ -14,8 +14,8 @@
  * limitations under the License.
  */
 
-import Foundation
 import FirebaseAuth
+import Foundation
 import XCTest
 
 class EmailPasswordTests: TestsBase {

+ 1 - 1
FirebaseAuth/Tests/Sample/SwiftApiTests/FacebookTests.swift

@@ -14,8 +14,8 @@
  * limitations under the License.
  */
 
-import Foundation
 import FirebaseAuth
+import Foundation
 import GTMSessionFetcher
 import XCTest
 

+ 1 - 1
FirebaseAuth/Tests/Sample/SwiftApiTests/GoogleTests.swift

@@ -14,8 +14,8 @@
  * limitations under the License.
  */
 
-import Foundation
 import FirebaseAuth
+import Foundation
 import GTMSessionFetcher
 import XCTest
 

+ 1 - 1
FirebaseAuth/Tests/Sample/SwiftApiTests/TestsBase.swift

@@ -14,8 +14,8 @@
  * limitations under the License.
  */
 
-import Foundation
 import FirebaseAuth
+import Foundation
 import XCTest
 
 class TestsBase: XCTestCase {

+ 1 - 1
FirebaseCombineSwift/Sources/Core/Core.swift

@@ -24,4 +24,4 @@ import Foundation
 #endif
 
 // This is here to appease the compiler.
-internal struct _Dummy {}
+struct _Dummy {}

+ 1 - 1
FirebaseCombineSwift/Sources/Storage/StorageReference+Combine.swift

@@ -14,9 +14,9 @@
 
 #if canImport(Combine) && swift(>=5.0)
 
-  import Foundation
   import Combine
   import FirebaseStorage
+  import Foundation
 
   @available(swift 5.0)
   @available(iOS 13.0, macOS 10.15, macCatalyst 13.0, tvOS 13.0, watchOS 6.0, *)

+ 1 - 1
FirebaseCombineSwift/Tests/Integration/Storage/StorageIntegration.swift

@@ -44,9 +44,9 @@
 
 import Combine
 import FirebaseAuth
+import FirebaseCombineSwift
 import FirebaseCore
 import FirebaseStorage
-import FirebaseCombineSwift
 import XCTest
 
 class StorageIntegration: XCTestCase {

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Auth/AnonymousAuthTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
+import Foundation
+import XCTest
 
 class AnonymousAuthTests: XCTestCase {
   static let apiKey = Credentials.apiKey

+ 1 - 1
FirebaseCombineSwift/Tests/Unit/Auth/AuthMocks.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 @testable import FirebaseAuth
+import Foundation
 
 let expectationTimeout: TimeInterval = 2
 

+ 3 - 3
FirebaseCombineSwift/Tests/Unit/Auth/AuthStateDidChangePublisherTests.swift

@@ -12,11 +12,11 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
-import FirebaseCore
+import Combine
 import FirebaseAuth
 import FirebaseCombineSwift
-import Combine
+import FirebaseCore
+import Foundation
 import XCTest
 
 class AuthStateDidChangePublisherTests: XCTestCase {

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Auth/EmailLinkAuthTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
+import Foundation
+import XCTest
 
 class EmailLinkAuthTests: XCTestCase {
   static let apiKey = Credentials.apiKey

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Auth/EmailPasswordAuthTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
+import Foundation
+import XCTest
 
 class EmailPasswordAuthTests: XCTestCase {
   override class func setUp() {

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Auth/FetchSignInMethodsTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
+import Foundation
+import XCTest
 
 class FetchSignInMethodsTests: XCTestCase {
   override class func setUp() {

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Auth/GameCenterAuthProviderTests.swift

@@ -12,11 +12,11 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
+import FirebaseAuth
+import Foundation
 import GameKit
 import XCTest
-import FirebaseAuth
 
 class GameCenterAuthProviderTests: XCTestCase {
   override class func setUp() {

+ 3 - 3
FirebaseCombineSwift/Tests/Unit/Auth/IDTokenDidChangePublisherTests.swift

@@ -12,11 +12,11 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
-import FirebaseCore
+import Combine
 import FirebaseAuth
 import FirebaseCombineSwift
-import Combine
+import FirebaseCore
+import Foundation
 import XCTest
 
 class IDTokenDidChangePublisherTests: XCTestCase {

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Auth/OAuthProviderTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
+import Foundation
+import XCTest
 
 class OAuthProviderTests: XCTestCase {
   override class func setUp() {

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Auth/PasswordResetTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
+import Foundation
+import XCTest
 
 class PasswordResetTests: XCTestCase {
   override class func setUp() {

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Auth/PhoneAuthProviderTests.swift

@@ -12,11 +12,11 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
 import FirebaseAuthTestingSupport
+import Foundation
+import XCTest
 
 class PhoneAuthProviderTests: XCTestCase {
   fileprivate static let phoneNumber = "55555555"

+ 8 - 10
FirebaseCombineSwift/Tests/Unit/Auth/SignInWithCredentialTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
+import Foundation
+import XCTest
 
 class SignInWithCredentialTests: XCTestCase {
   override class func setUp() {
@@ -55,14 +55,12 @@ class SignInWithCredentialTests: XCTestCase {
   static let googleAccessToken = "GOOGLE_ACCESS_TOKEN"
   static let googleDisplayName = "Google Doe"
   static let googleEmail = "user@gmail.com"
-  static let googleProfile: [String: String] = {
-    [
-      "iss": "https://accounts.google.com\\",
-      "email": googleEmail,
-      "given_name": "User",
-      "family_name": "Doe",
-    ]
-  }()
+  static let googleProfile: [String: String] = [
+    "iss": "https://accounts.google.com\\",
+    "email": googleEmail,
+    "given_name": "User",
+    "family_name": "Doe",
+  ]
 
   static let verificationCode = "12345678"
   static let verificationID = "55432"

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Auth/SignInWithCustomTokenTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
+import Foundation
+import XCTest
 
 class SignInWithCustomTokenTests: XCTestCase {
   override class func setUp() {

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Auth/SignInWithGameCenterTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
+import Foundation
+import XCTest
 
 class SignInWithGameCenterTests: XCTestCase {
   override class func setUp() {

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Auth/SignInWithProviderTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
+import Foundation
+import XCTest
 
 class SignInWithProviderTests: XCTestCase {
   override class func setUp() {

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Auth/UpdateCurrentUserTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
+import Foundation
+import XCTest
 
 class UpdateCurrentUserTests: XCTestCase {
   override class func setUp() {

+ 8 - 10
FirebaseCombineSwift/Tests/Unit/Auth/UserTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
+import Foundation
+import XCTest
 
 class UserTests: XCTestCase {
   override class func setUp() {
@@ -66,14 +66,12 @@ class UserTests: XCTestCase {
   fileprivate static let userName = "User Doe"
   fileprivate static let localID = "localId"
   fileprivate static let googleEmail = "user@gmail.com"
-  fileprivate static let googleProfile: [String: String] = {
-    [
-      "iss": "https://accounts.google.com\\",
-      "email": googleEmail,
-      "given_name": "User",
-      "family_name": "Doe",
-    ]
-  }()
+  fileprivate static let googleProfile: [String: String] = [
+    "iss": "https://accounts.google.com\\",
+    "email": googleEmail,
+    "given_name": "User",
+    "family_name": "Doe",
+  ]
 
   class MockGetAccountInfoResponse: FIRGetAccountInfoResponse {
     fileprivate var providerCredentials: ProviderCredentials!

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/AuthBackend+Combine.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 import FirebaseAuth
+import Foundation
+import XCTest
 
 extension FIRAuthBackend {
   class func signIn(withGameCenter request: FIRSignInWithGameCenterRequest)

+ 1 - 1
FirebaseCombineSwift/Tests/Unit/FirebaseApp+Tests.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import FirebaseCore
+import Foundation
 
 extension FirebaseApp {
   static func appOptions() -> FirebaseOptions {

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Firestore/GetDocumentsTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
+import Combine
 import FirebaseCombineSwift
 import FirebaseFirestoreTestingSupport
-import Combine
+import Foundation
 import XCTest
 
 class GetDocumentsTests: XCTestCase {

+ 2 - 2
FirebaseCombineSwift/Tests/Unit/Storage/StorageReferenceTests.swift

@@ -12,10 +12,10 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import Combine
-import XCTest
 @testable import FirebaseStorage
+import Foundation
+import XCTest
 
 class StorageReferenceTests: XCTestCase {
   override class func setUp() {

+ 1 - 1
FirebaseCore/Internal/Tests/Common/Assertions.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseCoreInternal
+import XCTest
 
 // MARK: - Assertions
 

+ 1 - 1
FirebaseCore/Internal/Tests/Integration/HeartbeatLoggingIntegrationTests.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseCoreInternal
+import XCTest
 
 class HeartbeatLoggingIntegrationTests: XCTestCase {
   // 2021-11-01 @ 00:00:00 (EST)

+ 1 - 1
FirebaseCore/Internal/Tests/Unit/HeartbeatControllerTests.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseCoreInternal
+import XCTest
 
 class HeartbeatControllerTests: XCTestCase {
   // 2021-11-01 @ 00:00:00 (EST)

+ 1 - 1
FirebaseCore/Internal/Tests/Unit/HeartbeatStorageTests.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseCoreInternal
+import XCTest
 class HeartbeatStorageTests: XCTestCase {
   // MARK: - Instance Management
 

+ 1 - 1
FirebaseCore/Internal/Tests/Unit/HeartbeatTests.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseCoreInternal
+import XCTest
 
 class TimePeriodTests: XCTestCase {
   override func setUpWithError() throws {

+ 1 - 1
FirebaseCore/Internal/Tests/Unit/HeartbeatsBundleTests.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseCoreInternal
+import XCTest
 
 class HeartbeatsBundleTests: XCTestCase {
   // 2021-11-01 @ 00:00:00 (EST)

+ 1 - 1
FirebaseCore/Internal/Tests/Unit/HeartbeatsPayloadTests.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseCoreInternal
+import XCTest
 
 class HeartbeatsPayloadTests: XCTestCase {
   func testPayloadCurrentVersion() throws {

+ 1 - 1
FirebaseCore/Internal/Tests/Unit/RingBufferTests.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseCoreInternal
+import XCTest
 
 class RingBufferTests: XCTestCase {
   // `RingBuffer` is a generic type. `String` is used for simplified testing.

+ 1 - 1
FirebaseCore/Internal/Tests/Unit/StorageTests.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseCoreInternal
+import XCTest
 
 private enum Constants {
   static let testData = "test_data".data(using: .utf8)!

+ 1 - 1
FirebaseCore/Internal/Tests/Unit/WeakContainerTests.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseCoreInternal
+import XCTest
 
 class WeakContainerTests: XCTestCase {
   func testContainersObjectIsWeaklyRetained() throws {

+ 1 - 1
FirebaseCore/Tests/SwiftUnit/FirebaseAppTests.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseCore
+import XCTest
 
 private extension Constants {
   static let testAppName1 = "test_app_name_1"

+ 1 - 1
FirebaseCore/Tests/SwiftUnit/FirebaseConfigurationTests.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseCore
+import XCTest
 
 class FirebaseConfigurationTests: XCTestCase {
   func testSharedInstance() {

+ 1 - 1
FirebaseCore/Tests/SwiftUnit/FirebaseOptionsTests.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import XCTest
 @testable import FirebaseCore
+import XCTest
 
 class FirebaseOptionsTests: XCTestCase {
   func testDefaultOptions() throws {

+ 1 - 1
FirebaseFunctions/Sources/Callable+Codable.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import FirebaseSharedSwift
+import Foundation
 
 // A `Callable` is reference to a particular Callable HTTPS trigger in Cloud Functions.
 public struct Callable<Request: Encodable, Response: Decodable> {

+ 25 - 25
FirebaseFunctions/Sources/Functions.swift

@@ -12,12 +12,12 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import FirebaseAppCheckInterop
 import FirebaseAuthInterop
 import FirebaseCore
 import FirebaseMessagingInterop
 import FirebaseSharedSwift
+import Foundation
 #if COCOAPODS
   import GTMSessionFetcher
 #else
@@ -34,7 +34,7 @@ private enum Constants {
 }
 
 /// Cross SDK constants.
-internal enum FunctionsConstants {
+enum FunctionsConstants {
   static let defaultRegion = "us-central1"
 }
 
@@ -54,10 +54,10 @@ internal enum FunctionsConstants {
   private let contextProvider: FunctionsContextProvider
 
   /// The custom domain to use for all functions references (optional).
-  internal let customDomain: String?
+  let customDomain: String?
 
   /// The region to use for all function references.
-  internal let region: String
+  let region: String
 
   // MARK: - Public APIs
 
@@ -314,13 +314,13 @@ internal enum FunctionsConstants {
                                type: self)
   }
 
-  @objc internal init(projectID: String,
-                      region: String,
-                      customDomain: String?,
-                      auth: AuthInterop?,
-                      messaging: MessagingInterop?,
-                      appCheck: AppCheckInterop?,
-                      fetcherService: GTMSessionFetcherService = GTMSessionFetcherService()) {
+  @objc init(projectID: String,
+             region: String,
+             customDomain: String?,
+             auth: AuthInterop?,
+             messaging: MessagingInterop?,
+             appCheck: AppCheckInterop?,
+             fetcherService: GTMSessionFetcherService = GTMSessionFetcherService()) {
     self.projectID = projectID
     self.region = region
     self.customDomain = customDomain
@@ -332,9 +332,9 @@ internal enum FunctionsConstants {
   }
 
   /// Using the component system for initialization.
-  internal convenience init(app: FirebaseApp,
-                            region: String,
-                            customDomain: String?) {
+  convenience init(app: FirebaseApp,
+                   region: String,
+                   customDomain: String?) {
     // TODO: These are not optionals, but they should be.
     let auth = ComponentType<AuthInterop>.instance(for: AuthInterop.self, in: app.container)
     let messaging = ComponentType<MessagingInterop>.instance(for: MessagingInterop.self,
@@ -354,7 +354,7 @@ internal enum FunctionsConstants {
               appCheck: appCheck)
   }
 
-  internal func urlWithName(_ name: String) -> String {
+  func urlWithName(_ name: String) -> String {
     assert(!name.isEmpty, "Name cannot be empty")
 
     // Check if we're using the emulator
@@ -370,11 +370,11 @@ internal enum FunctionsConstants {
     return "https://\(region)-\(projectID).cloudfunctions.net/\(name)"
   }
 
-  internal func callFunction(name: String,
-                             withObject data: Any?,
-                             options: HTTPSCallableOptions?,
-                             timeout: TimeInterval,
-                             completion: @escaping ((Result<HTTPSCallableResult, Error>) -> Void)) {
+  func callFunction(name: String,
+                    withObject data: Any?,
+                    options: HTTPSCallableOptions?,
+                    timeout: TimeInterval,
+                    completion: @escaping ((Result<HTTPSCallableResult, Error>) -> Void)) {
     // Get context first.
     contextProvider.getContext(options: options) { context, error in
       // Note: context is always non-nil since some checks could succeed, we're only failing if
@@ -393,11 +393,11 @@ internal enum FunctionsConstants {
     }
   }
 
-  internal func callFunction(url: URL,
-                             withObject data: Any?,
-                             options: HTTPSCallableOptions?,
-                             timeout: TimeInterval,
-                             completion: @escaping ((Result<HTTPSCallableResult, Error>) -> Void)) {
+  func callFunction(url: URL,
+                    withObject data: Any?,
+                    options: HTTPSCallableOptions?,
+                    timeout: TimeInterval,
+                    completion: @escaping ((Result<HTTPSCallableResult, Error>) -> Void)) {
     // Get context first.
     contextProvider.getContext(options: options) { context, error in
       // Note: context is always non-nil since some checks could succeed, we're only failing if

+ 4 - 4
FirebaseFunctions/Sources/FunctionsError.swift

@@ -108,7 +108,7 @@ public let FunctionsErrorDetailsKey: String = "details"
  * - Parameter status An HTTP status code.
  * - Returns: The corresponding error code, or `FIRFunctionsErrorCodeUnknown` if none.
  */
-internal func FunctionsCodeForHTTPStatus(_ status: NSInteger) -> FunctionsErrorCode {
+func FunctionsCodeForHTTPStatus(_ status: NSInteger) -> FunctionsErrorCode {
   switch status {
   case 200:
     return .OK
@@ -209,9 +209,9 @@ extension FunctionsErrorCode {
   }
 }
 
-internal func FunctionsErrorForResponse(status: NSInteger,
-                                        body: Data?,
-                                        serializer: FUNSerializer) -> NSError? {
+func FunctionsErrorForResponse(status: NSInteger,
+                               body: Data?,
+                               serializer: FUNSerializer) -> NSError? {
   // Start with reasonable defaults from the status code.
   var code = FunctionsCodeForHTTPStatus(status)
   var description = code.descriptionForErrorCode

+ 3 - 3
FirebaseFunctions/Sources/HTTPSCallable.swift

@@ -28,7 +28,7 @@ open class HTTPSCallableResult: NSObject {
    */
   @objc public let data: Any
 
-  internal init(data: Any) {
+  init(data: Any) {
     self.data = data
   }
 }
@@ -59,13 +59,13 @@ open class HTTPSCallable: NSObject {
    */
   @objc open var timeoutInterval: TimeInterval = 70
 
-  internal init(functions: Functions, name: String, options: HTTPSCallableOptions? = nil) {
+  init(functions: Functions, name: String, options: HTTPSCallableOptions? = nil) {
     self.functions = functions
     self.options = options
     endpoint = .name(name)
   }
 
-  internal init(functions: Functions, url: URL, options: HTTPSCallableOptions? = nil) {
+  init(functions: Functions, url: URL, options: HTTPSCallableOptions? = nil) {
     self.functions = functions
     self.options = options
     endpoint = .url(url)

+ 1 - 1
FirebaseFunctions/Sources/Internal/FunctionsComponent.swift

@@ -12,11 +12,11 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import FirebaseAppCheckInterop
 import FirebaseAuthInterop
 import FirebaseCore
 import FirebaseMessagingInterop
+import Foundation
 
 // Avoids exposing internal FirebaseCore APIs to Swift users.
 @_implementationOnly import FirebaseCoreExtension

+ 5 - 5
FirebaseFunctions/Sources/Internal/FunctionsContext.swift

@@ -12,13 +12,13 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import FirebaseAppCheckInterop
 import FirebaseAuthInterop
 import FirebaseMessagingInterop
+import Foundation
 
 /// FunctionsContext is a helper class for gathering metadata for a function call.
-internal class FunctionsContext: NSObject {
+class FunctionsContext: NSObject {
   let authToken: String?
   let fcmToken: String?
   let appCheckToken: String?
@@ -33,7 +33,7 @@ internal class FunctionsContext: NSObject {
   }
 }
 
-internal class FunctionsContextProvider: NSObject {
+class FunctionsContextProvider: NSObject {
   private var auth: AuthInterop?
   private var messaging: MessagingInterop?
   private var appCheck: AppCheckInterop?
@@ -51,8 +51,8 @@ internal class FunctionsContextProvider: NSObject {
 //
 //  }
 
-  internal func getContext(options: HTTPSCallableOptions? = nil,
-                           _ completion: @escaping ((FunctionsContext, Error?) -> Void)) {
+  func getContext(options: HTTPSCallableOptions? = nil,
+                  _ completion: @escaping ((FunctionsContext, Error?) -> Void)) {
     let dispatchGroup = DispatchGroup()
 
     var authToken: String?

+ 2 - 2
FirebaseFunctions/Sources/Internal/FunctionsSerializer.swift

@@ -38,7 +38,7 @@ class FUNSerializer: NSObject {
 
   // MARK: - Internal APIs
 
-  internal func encode(_ object: Any) throws -> AnyObject {
+  func encode(_ object: Any) throws -> AnyObject {
     if object is NSNull {
       return object as AnyObject
     } else if object is NSNumber {
@@ -71,7 +71,7 @@ class FUNSerializer: NSObject {
     }
   }
 
-  internal func decode(_ object: Any) throws -> AnyObject? {
+  func decode(_ object: Any) throws -> AnyObject? {
     // Return these types as is. PORTING NOTE: Moved from the bottom of the func for readability.
     if let dict = object as? NSDictionary {
       if let requestedType = dict["@type"] as? String {

+ 2 - 2
FirebaseFunctions/Tests/CombineUnit/HTTPSCallableTests.swift

@@ -15,11 +15,11 @@
 import Foundation
 
 import Combine
+import FirebaseAppCheckInterop
+import FirebaseAuthInterop
 import FirebaseCore
 @testable import FirebaseFunctions
 import FirebaseFunctionsCombineSwift
-import FirebaseAuthInterop
-import FirebaseAppCheckInterop
 import FirebaseMessagingInterop
 import GTMSessionFetcherCore
 import XCTest

+ 1 - 1
FirebaseFunctions/Tests/Integration/IntegrationTests.swift

@@ -14,8 +14,8 @@
 
 import Foundation
 
-@testable import FirebaseFunctions
 import FirebaseAuthInterop
+@testable import FirebaseFunctions
 import FirebaseMessagingInterop
 import XCTest
 

+ 1 - 1
FirebaseFunctions/Tests/Unit/FunctionsTests.swift

@@ -22,8 +22,8 @@ import FirebaseCore
   import GTMSessionFetcherCore
 #endif
 
-import XCTest
 import SharedTestUtilities
+import XCTest
 
 class FunctionsTests: XCTestCase {
   var functions: Functions?

+ 1 - 1
FirebaseInAppMessaging/Swift/Tests/Integration/FIAMSwiftUI/Shared/ContentView.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import SwiftUI
 import FirebaseInAppMessaging
+import SwiftUI
 
 struct ContentView: View {
   @State private var analyticsEvent = ""

+ 1 - 1
FirebaseInAppMessaging/Swift/Tests/Integration/FIAMSwiftUI/Shared/ModalInAppMessageView.swift

@@ -12,9 +12,9 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import SwiftUI
 import FirebaseInAppMessaging
 import FirebaseInAppMessagingSwift
+import SwiftUI
 
 struct ModalInAppMessageView: View {
   var modalMessage: InAppMessagingModalDisplay

+ 1 - 1
FirebaseMLModelDownloader/Apps/Sample/MLDownloaderTestApp/AppDelegate.swift

@@ -12,9 +12,9 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import UIKit
 import FirebaseCore
 import FirebaseMLModelDownloader
+import UIKit
 
 @main
 class AppDelegate: UIResponder, UIApplicationDelegate {

+ 1 - 1
FirebaseMLModelDownloader/Apps/Sample/MLDownloaderTestApp/ContentView.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import SwiftUI
 import FirebaseMLModelDownloader
+import SwiftUI
 
 struct ContentView: View {
   var downloadTotal: Float = 1.0

+ 1 - 1
FirebaseMLModelDownloader/Apps/Sample/MLDownloaderTestApp/Downloader.swift

@@ -12,9 +12,9 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
+import FirebaseMLModelDownloader
 import Foundation
 import TensorFlowLite
-import FirebaseMLModelDownloader
 
 class Downloader: ObservableObject {
   @Published var downloadProgress: Float = 0.0

+ 1 - 1
FirebaseMLModelDownloader/Apps/Sample/MLDownloaderTestApp/SceneDelegate.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import UIKit
 import SwiftUI
+import UIKit
 
 class SceneDelegate: UIResponder, UIWindowSceneDelegate {
   var window: UIWindow?

+ 1 - 1
FirebaseMLModelDownloader/Sources/ModelDownloader.swift

@@ -12,9 +12,9 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import FirebaseCore
 import FirebaseInstallations
+import Foundation
 
 /// Possible ways to get a custom model.
 public enum ModelDownloadType {

+ 1 - 1
FirebaseMLModelDownloader/Sources/ModelInfoRetriever.swift

@@ -12,9 +12,9 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import FirebaseCore
 import FirebaseInstallations
+import Foundation
 
 /// URL Session to use while retrieving model info.
 protocol ModelInfoRetrieverSession {

+ 1 - 1
FirebaseMLModelDownloader/Sources/TelemetryLogger.swift

@@ -12,8 +12,8 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-import Foundation
 import FirebaseCore
+import Foundation
 import GoogleDataTransport
 
 /// Extension to set Firebase app info.

+ 1 - 1
FirebaseMLModelDownloader/Tests/Integration/ModelDownloaderIntegrationTests.swift

@@ -18,10 +18,10 @@
 // See go/firebase-macos-keychain-popups for more details.
 #if !targetEnvironment(macCatalyst) && !os(macOS)
 
-  import XCTest
   @testable import FirebaseCore
   @testable import FirebaseInstallations
   @testable import FirebaseMLModelDownloader
+  import XCTest
 
   extension UserDefaults {
     /// Returns a new cleared instance of user defaults.

Einige Dateien werden nicht angezeigt, da zu viele Dateien in diesem Diff geändert wurden.