From 7a9b473d4c3df75a4bff185e0b816e915fbd85b6 Mon Sep 17 00:00:00 2001 From: Gabriel Minucci Date: Mon, 27 Jan 2025 13:57:19 +0100 Subject: [PATCH] fix: linter and danger errors --- Sources/VariantsCore/Factory/iOS/XCConfigFactory.swift | 4 ++++ Sources/VariantsCore/Schemas/iOS/iOSExtension.swift | 4 ++-- Tests/VariantsCoreTests/iOSTargetExtensionTests.swift | 6 ++---- Tests/VariantsCoreTests/iOSVariantTests.swift | 2 +- 4 files changed, 9 insertions(+), 7 deletions(-) diff --git a/Sources/VariantsCore/Factory/iOS/XCConfigFactory.swift b/Sources/VariantsCore/Factory/iOS/XCConfigFactory.swift index 35240a9..9113b3c 100644 --- a/Sources/VariantsCore/Factory/iOS/XCConfigFactory.swift +++ b/Sources/VariantsCore/Factory/iOS/XCConfigFactory.swift @@ -5,6 +5,8 @@ // Created by Arthur Alves // +// swiftlint:disable file_length + import Foundation import ArgumentParser import PathKit @@ -255,3 +257,5 @@ class XCConfigFactory: XCFactory { let xcconfigFileName: String = "variants.xcconfig" let logger: Logger } + +// swiftlint:enable file_length diff --git a/Sources/VariantsCore/Schemas/iOS/iOSExtension.swift b/Sources/VariantsCore/Schemas/iOS/iOSExtension.swift index fa1579e..4105df5 100644 --- a/Sources/VariantsCore/Schemas/iOS/iOSExtension.swift +++ b/Sources/VariantsCore/Schemas/iOS/iOSExtension.swift @@ -1,7 +1,7 @@ // -// iOSExtension.swift -// VariantsCore +// Variants // +// Copyright (c) Backbase B.V. - https://www.backbase.com // Created by Gabriel Rodrigues Minucci on 24/01/2025. // diff --git a/Tests/VariantsCoreTests/iOSTargetExtensionTests.swift b/Tests/VariantsCoreTests/iOSTargetExtensionTests.swift index 3c04f11..39913bd 100644 --- a/Tests/VariantsCoreTests/iOSTargetExtensionTests.swift +++ b/Tests/VariantsCoreTests/iOSTargetExtensionTests.swift @@ -1,7 +1,7 @@ // -// iOSTargetExtensionTests.swift -// VariantsCoreTests +// Variants // +// Copyright (c) Backbase B.V. - https://www.backbase.com // Created by Gabriel Rodrigues Minucci on 27/01/2025. // @@ -16,7 +16,6 @@ class iOSTargetExtensionTests: XCTestCase { private let target = iOSTarget(name: "Target Name", app_icon: "AppIcon", bundleId: "com.Company.ValidName", testTarget: "ValidNameTests", source: iOSSource(path: "", info: "", config: "")) func testTargetExtensionCreationWithBundleSuffix() { - let variantBundleID = "com.test.Application" guard let variant = try? iOSVariant( name: name, versionName: "1.0.0", versionNumber: 0, appIcon: nil, appName: nil, storeDestination: "appStore", idSuffix: "beta", bundleID: nil, globalCustomProperties: nil, variantCustomProperties: nil, @@ -40,7 +39,6 @@ class iOSTargetExtensionTests: XCTestCase { } func testTargetExtensionCreationWithBundleID() { - let variantBundleID = "com.test.Application" guard let variant = try? iOSVariant( name: name, versionName: "1.0.0", versionNumber: 0, appIcon: nil, appName: nil, storeDestination: "appStore", idSuffix: "beta", bundleID: nil, globalCustomProperties: nil, variantCustomProperties: nil, diff --git a/Tests/VariantsCoreTests/iOSVariantTests.swift b/Tests/VariantsCoreTests/iOSVariantTests.swift index e85bb57..61f2cdc 100644 --- a/Tests/VariantsCoreTests/iOSVariantTests.swift +++ b/Tests/VariantsCoreTests/iOSVariantTests.swift @@ -263,7 +263,7 @@ class iOSVariantTests: XCTestCase { globalSigning: nil, variantSigning: nil, globalPostSwitchScript: nil, variantPostSwitchScript: nil) } - XCTAssertNoThrow(try makeiOSVariant()) + XCTAssertThrowsError(try makeiOSVariant()) } func testGetDefaultValuesForTargetWithoutSigning() {