Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexKuzyaev committed Sep 25, 2023
1 parent fa8d822 commit bea7612
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 5 deletions.
2 changes: 2 additions & 0 deletions Sources/VariantsCore/Schemas/iOS/iOSVariant.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import Foundation

// swiftlint:disable type_name
// swiftlint:disable line_length

public struct iOSVariant: Variant {
let name: String
Expand Down Expand Up @@ -225,3 +226,4 @@ extension iOSVariant {
}

// swiftlint:enable type_name
// swiftlint:enable line_length
8 changes: 6 additions & 2 deletions Tests/VariantsCoreTests/FastlaneParametersFactoryTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ import XCTest
import PathKit
@testable import VariantsCore

// swiftlint:disable function_body_length

private let parameters = [
CustomProperty(name: "sample", value: "sample-value", destination: .project),
CustomProperty(name: "sample-2", value: "sample-2-value", destination: .fastlane),
Expand Down Expand Up @@ -135,8 +137,8 @@ class FastlaneParametersFactoryTests: XCTestCase {
bundleID: nil,
variantSigning: nil,
globalSigning: iOSSigning(teamName: "", teamID: "", exportMethod: .appstore, matchURL: ""),
variantPostSwitchScript: "echo hello",
globalPostSwitchScript: "echo test")
globalPostSwitchScript: "echo global",
variantPostSwitchScript: "echo variant")
else {
return XCTFail("Failed to initialize iOSVariant with provided parameters")
}
Expand Down Expand Up @@ -203,3 +205,5 @@ fileprivate extension Sequence where Iterator.Element == CustomProperty {
.filter({ $0.destination == .fastlane && !$0.isEnvironmentVariable })
}
}

// swiftlint:enable function_body_length
4 changes: 2 additions & 2 deletions Tests/VariantsCoreTests/VariantsFileFactoryTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ class VariantsFileFactoryTests: XCTestCase {
bundleID: nil,
variantSigning: nil,
globalSigning: iOSSigning(teamName: "", teamID: "", exportMethod: .appstore, matchURL: ""),
variantPostSwitchScript: "echo hello",
globalPostSwitchScript: "echo test")
globalPostSwitchScript: "echo global",
variantPostSwitchScript: "echo variant")

func testRender_noSecrets() {
guard let configFile = Bundle(for: type(of: self))
Expand Down
2 changes: 1 addition & 1 deletion Tests/VariantsCoreTests/XcodeProjFactoryTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class XcodeProjFactoryTests: XCTestCase {
guard let variant = try? iOSVariant(name: target.name, versionName: "", versionNumber: 0, appIcon: nil, appName: nil,
storeDestination: nil, custom: nil, idSuffix: "", bundleID: nil, variantSigning: nil,
globalSigning: iOSSigning(teamName: "", teamID: "", exportMethod: .appstore, matchURL: ""),
variantPostSwitchScript: nil, globalPostSwitchScript: nil)
globalPostSwitchScript: nil, variantPostSwitchScript: nil)
else {
return XCTFail("Failed to initialize iOSVariant with provided parameters")
}
Expand Down

0 comments on commit bea7612

Please sign in to comment.