diff --git a/WireAPI/Sources/WireAPI/APIs/AccountsAPI/AccountsAPIV7.swift b/WireAPI/Sources/WireAPI/APIs/AccountsAPI/AccountsAPIV7.swift index 43268c8eb85..cd89ad94d73 100644 --- a/WireAPI/Sources/WireAPI/APIs/AccountsAPI/AccountsAPIV7.swift +++ b/WireAPI/Sources/WireAPI/APIs/AccountsAPI/AccountsAPIV7.swift @@ -35,7 +35,7 @@ class AccountsAPIV7: AccountsAPIV6 { let encodedJSON: Data do { - encodedJSON = try JSONEncoder().encode(body) + encodedJSON = try JSONEncoder.defaultEncoder.encode(body) } catch { assertionFailure("failed to encode body") throw AccountsAPIError.invalidRequestBody diff --git a/WireAPI/Tests/TestPlans/AllTests.xctestplan b/WireAPI/Tests/TestPlans/AllTests.xctestplan index e8951419670..c858afa9242 100644 --- a/WireAPI/Tests/TestPlans/AllTests.xctestplan +++ b/WireAPI/Tests/TestPlans/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireAPI", + "identifier" : "WireAPITests", + "name" : "WireAPITests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/WireAPI/Tests/WireAPITests/APIs/AccountsAPI/__Snapshots__/AccountsAPITests/testUpgradeToTeam_Request_Generation_V7_Onwards.request-0-v7.txt b/WireAPI/Tests/WireAPITests/APIs/AccountsAPI/__Snapshots__/AccountsAPITests/testUpgradeToTeam_Request_Generation_V7_Onwards.request-0-v7.txt index 06358db4202..0fae195f0be 100644 --- a/WireAPI/Tests/WireAPITests/APIs/AccountsAPI/__Snapshots__/AccountsAPITests/testUpgradeToTeam_Request_Generation_V7_Onwards.request-0-v7.txt +++ b/WireAPI/Tests/WireAPITests/APIs/AccountsAPI/__Snapshots__/AccountsAPITests/testUpgradeToTeam_Request_Generation_V7_Onwards.request-0-v7.txt @@ -1,5 +1,5 @@ curl \ --request POST \ --header "Content-Type: application/json" \ - --data "{\"name\":\"iOS Team\",\"icon\":\"default\"}" \ + --data "{\"icon\":\"default\",\"name\":\"iOS Team\"}" \ "upgrade-personal-to-team" \ No newline at end of file diff --git a/WireAPI/Tests/WireAPITests/Helpers/HTTPRequestSnapshotHelper.swift b/WireAPI/Tests/WireAPITests/Helpers/HTTPRequestSnapshotHelper.swift index 55fb1455f17..a232543794e 100644 --- a/WireAPI/Tests/WireAPITests/Helpers/HTTPRequestSnapshotHelper.swift +++ b/WireAPI/Tests/WireAPITests/Helpers/HTTPRequestSnapshotHelper.swift @@ -24,6 +24,11 @@ import struct WireAPI.HTTPRequest /// Provides convenience to snapshot `HTTPRequest` objects. struct HTTPRequestSnapshotHelper { + private var defaultRecordMode: SnapshotTestingConfiguration.Record? { + let ci = ProcessInfo.processInfo.environment["CI"] + return (ci == nil || ci?.isEmpty == true) ? .missing : .never + } + /// Snapshot test a given request /// - Parameters: /// - request: httpRequest to verify @@ -40,9 +45,7 @@ struct HTTPRequestSnapshotHelper { function: String = #function, line: UInt = #line ) { - let recordEnabled: SnapshotTestingConfiguration.Record? = ProcessInfo.processInfo - .environment["CI"] == "true" ? .never : nil - withSnapshotTesting(record: recordEnabled) { + withSnapshotTesting(record: defaultRecordMode) { let errorMessage = verifySnapshot( of: request, as: .dump, @@ -62,7 +65,8 @@ struct HTTPRequestSnapshotHelper { /// - Parameters: /// - request: url request to verify /// - resourceName: name of the file containing the expected request description - /// - record: if true, a new snapshot will be recorded, overwriting an existing snapshot. + /// - record: if true, a new snapshot will be recorded, overwriting an existing snapshot. If false it record only + /// if missing. If nil, it fallbacks to defaultRecordMode /// - file: The file invoking the test. /// - function: The method invoking the test. /// - line: The line invoking the test. @@ -71,14 +75,12 @@ struct HTTPRequestSnapshotHelper { func verifyRequest( request: URLRequest, resourceName: String? = nil, - record: Bool = false, + record: Bool? = nil, file: StaticString = #filePath, function: String = #function, line: UInt = #line ) { - let recordEnabled: SnapshotTestingConfiguration.Record? = ProcessInfo.processInfo - .environment["CI"] == "true" ? .never : nil - withSnapshotTesting(record: recordEnabled) { + withSnapshotTesting(record: defaultRecordMode) { let errorMessage = verifySnapshot( of: request, as: .curl, diff --git a/WireAnalytics/Tests/TestPlans/AllTests.xctestplan b/WireAnalytics/Tests/TestPlans/AllTests.xctestplan index 1ce51f179d1..569718e063e 100644 --- a/WireAnalytics/Tests/TestPlans/AllTests.xctestplan +++ b/WireAnalytics/Tests/TestPlans/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireAnalytics", + "identifier" : "WireAnalyticsTests", + "name" : "WireAnalyticsTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/WireDomain/Project/TestPlans/AllTests.xctestplan b/WireDomain/Project/TestPlans/AllTests.xctestplan index 8607d870983..427f9eae3aa 100644 --- a/WireDomain/Project/TestPlans/AllTests.xctestplan +++ b/WireDomain/Project/TestPlans/AllTests.xctestplan @@ -9,8 +9,24 @@ } ], "defaultOptions" : { + "commandLineArgumentEntries" : [ + { + "argument" : "-com.apple.CoreData.ConcurrencyDebug 1" + } + ], + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireDomain Project.xcodeproj", + "identifier" : "01D0DCAF2C1C8C880076CB1C", + "name" : "WireDomainTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/WireDomain/Tests/TestPlans/AllTests.xctestplan b/WireDomain/Tests/TestPlans/AllTests.xctestplan index 444f2ef0e81..3e366631f81 100644 --- a/WireDomain/Tests/TestPlans/AllTests.xctestplan +++ b/WireDomain/Tests/TestPlans/AllTests.xctestplan @@ -14,8 +14,19 @@ "argument" : "-com.apple.CoreData.ConcurrencyDebug 1" } ], + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireDomain", + "identifier" : "WireDomainPkgTests", + "name" : "WireDomainPkgTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/WireFoundation/Sources/WireTesting/Utilities/SnapshotHelper.swift b/WireFoundation/Sources/WireTesting/Utilities/SnapshotHelper.swift index 5dfedce4011..1d247695b1b 100644 --- a/WireFoundation/Sources/WireTesting/Utilities/SnapshotHelper.swift +++ b/WireFoundation/Sources/WireTesting/Utilities/SnapshotHelper.swift @@ -32,6 +32,11 @@ public struct SnapshotHelper { /// If empty, the `SNAPSHOT_REFERENCE_DIR` environment variable is read. private var snapshotReferenceDirectory = "" + private var defaultRecordMode: SnapshotTestingConfiguration.Record? { + let ci = ProcessInfo.processInfo.environment["CI"] + return (ci == nil || ci?.isEmpty == true) ? .missing : .never + } + public init() {} // MARK: - Create variations @@ -143,9 +148,7 @@ public struct SnapshotHelper { let snapshotDirectory = snapshotDirectory(file: file) setArtifactsDirectoryIfNeeded(basedOn: snapshotDirectory) - let recordEnabled: SnapshotTestingConfiguration.Record? = ProcessInfo.processInfo - .environment["CI"] == "true" ? .never : nil - withSnapshotTesting(record: recordEnabled) { + withSnapshotTesting(record: defaultRecordMode) { let failure = verifySnapshot( of: value, as: .image( @@ -190,9 +193,7 @@ public struct SnapshotHelper { setArtifactsDirectoryIfNeeded(basedOn: snapshotDirectory) let config = size.map { ViewImageConfig(safeArea: safeArea, size: $0, traits: traits) } - let recordEnabled: SnapshotTestingConfiguration.Record? = ProcessInfo.processInfo - .environment["CI"] == "true" ? .never : nil - withSnapshotTesting(record: recordEnabled) { + withSnapshotTesting(record: defaultRecordMode) { let failure = verifySnapshot( of: value, as: config.map { .image(on: $0, perceptualPrecision: perceptualPrecision, traits: traits) } ?? .image( @@ -229,9 +230,7 @@ public struct SnapshotHelper { ) { let snapshotDirectory = snapshotDirectory(file: file) setArtifactsDirectoryIfNeeded(basedOn: snapshotDirectory) - let recordEnabled: SnapshotTestingConfiguration.Record? = ProcessInfo.processInfo - .environment["CI"] == "true" ? .never : nil - withSnapshotTesting(record: recordEnabled) { + withSnapshotTesting(record: defaultRecordMode) { let failure = verifySnapshot( of: value, as: .image(perceptualPrecision: perceptualPrecision, traits: traits), @@ -312,9 +311,7 @@ public struct SnapshotHelper { ) { let snapshotDirectory = snapshotDirectory(file: file) setArtifactsDirectoryIfNeeded(basedOn: snapshotDirectory) - let recordEnabled: SnapshotTestingConfiguration.Record? = ProcessInfo.processInfo - .environment["CI"] == "true" ? .never : nil - withSnapshotTesting(record: recordEnabled) { + withSnapshotTesting(record: defaultRecordMode) { for (config, name) in SnapshotHelper.phoneConfigs { let failure = verifySnapshot( @@ -352,9 +349,7 @@ public struct SnapshotHelper { ) { let snapshotDirectory = snapshotDirectory(file: file) setArtifactsDirectoryIfNeeded(basedOn: snapshotDirectory) - let recordEnabled: SnapshotTestingConfiguration.Record? = ProcessInfo.processInfo - .environment["CI"] == "true" ? .never : nil - withSnapshotTesting(record: recordEnabled) { + withSnapshotTesting(record: defaultRecordMode) { let failure = verifySnapshot( of: value, as: .image, @@ -385,9 +380,7 @@ public struct SnapshotHelper { testName: String = #function, line: UInt = #line ) { - let recordEnabled: SnapshotTestingConfiguration.Record? = ProcessInfo.processInfo - .environment["CI"] == "true" ? .never : nil - withSnapshotTesting(record: recordEnabled) { + withSnapshotTesting(record: defaultRecordMode) { let snapshotDirectory = snapshotDirectory(file: file) setArtifactsDirectoryIfNeeded(basedOn: snapshotDirectory) diff --git a/WireFoundation/Tests/TestPlans/AllTests.xctestplan b/WireFoundation/Tests/TestPlans/AllTests.xctestplan index 046f6d4b16b..e8feb31b955 100644 --- a/WireFoundation/Tests/TestPlans/AllTests.xctestplan +++ b/WireFoundation/Tests/TestPlans/AllTests.xctestplan @@ -9,21 +9,25 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireFoundation", + "identifier" : "WireFoundationTests", + "name" : "WireFoundationTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ { "target" : { - "containerPath" : "container:WireFoundation", - "identifier" : "WireLoggingTests", - "name" : "WireLoggingTests" - } - }, - { - "target" : { - "containerPath" : "container:WireFoundation", + "containerPath" : "container:", "identifier" : "WireFoundationTests", "name" : "WireFoundationTests" } diff --git a/WireLogging/Tests/TestPlans/AllTests.xctestplan b/WireLogging/Tests/TestPlans/AllTests.xctestplan index f366f3d093a..cc137d225d8 100644 --- a/WireLogging/Tests/TestPlans/AllTests.xctestplan +++ b/WireLogging/Tests/TestPlans/AllTests.xctestplan @@ -10,7 +10,18 @@ ], "defaultOptions" : { "codeCoverage" : false, - "language" : "en" + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], + "language" : "en", + "targetForVariableExpansion" : { + "containerPath" : "container:WireLogging", + "identifier" : "WireLoggingTests", + "name" : "WireLoggingTests" + } }, "testTargets" : [ { diff --git a/WireUI/Tests/TestPlans/AllTests.xctestplan b/WireUI/Tests/TestPlans/AllTests.xctestplan index dca03f2a326..7e982d3333a 100644 --- a/WireUI/Tests/TestPlans/AllTests.xctestplan +++ b/WireUI/Tests/TestPlans/AllTests.xctestplan @@ -14,8 +14,19 @@ "argument" : "-NSShowNonLocalizedStrings YES" } ], + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireUI", + "identifier" : "WireDesignTests", + "name" : "WireDesignTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ @@ -81,13 +92,6 @@ "identifier" : "WireReusableUIComponentsTests", "name" : "WireReusableUIComponentsTests" } - }, - { - "target" : { - "containerPath" : "container:WireUI", - "identifier" : "WireIndividualToTeamMigrationUITests", - "name" : "WireIndividualToTeamMigrationUITests" - } } ], "version" : 1 diff --git a/fastlane/Fastfile b/fastlane/Fastfile index bbb9fbe0b92..54bcc7856f4 100644 --- a/fastlane/Fastfile +++ b/fastlane/Fastfile @@ -42,7 +42,7 @@ platform :ios do before_all do |lane| ensure_xcode_version - create_keychain_if_needed unless [:prepare_for_tests, :select_frameworks, :generate_framework_list, :test_frameworks].include?(lane) + create_keychain_if_needed unless [:prepare_for_tests, :select_framework, :select_frameworks, :generate_framework_list, :test_frameworks].include?(lane) `mkdir -p ./.post_build` Dir.chdir("..") do encoded_key = ENV['APPSTORE_API_KEY_BASE64'] @@ -81,9 +81,14 @@ platform :ios do desc "Test one framework only" lane :select_framework do |options| frameworks = Framework.all.values - framework_options = frameworks.map { |f| f.scheme } - selected_choice = UI.select("Select a framework for testing:", framework_options) + if (!options[:scheme].nil?) + selected_choice = options[:scheme] + else + framework_options = frameworks.map { |f| f.scheme } + selected_choice = UI.select("Select a framework for testing:", framework_options) + end + framework = frameworks.find { |framework| framework.scheme == selected_choice } run_tests_frameworks([framework.scheme], options) @@ -512,6 +517,8 @@ platform :ios do raise e # Stops execution immediately if the build fails end + ci_args = is_running_on_ci ? "CI=1" : nil + begin UI.message "🧪 Running tests for scheme: #{scheme}" run_tests( @@ -532,6 +539,7 @@ platform :ios do skip_package_dependencies_resolution: true, number_of_retries: 2, test_without_building: true, + xcargs: ci_args ) rescue => e puts "⚠️ Tests failed for scheme: #{scheme}, but continuing..." diff --git a/scripts/AllTests.xctestplan b/scripts/AllTests.xctestplan index 243ac205660..b1c3e35c66c 100644 --- a/scripts/AllTests.xctestplan +++ b/scripts/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:", + "identifier" : "TrimStringCatalogsTests", + "name" : "TrimStringCatalogsTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios-canvas/WireCanvasTests/TestPlans/AllTests.xctestplan b/wire-ios-canvas/WireCanvasTests/TestPlans/AllTests.xctestplan index d0acbe8ec13..ed30b55c1ee 100644 --- a/wire-ios-canvas/WireCanvasTests/TestPlans/AllTests.xctestplan +++ b/wire-ios-canvas/WireCanvasTests/TestPlans/AllTests.xctestplan @@ -9,6 +9,17 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], + "targetForVariableExpansion" : { + "containerPath" : "container:WireCanvas.xcodeproj", + "identifier" : "01E9445F2D01805B006921E4", + "name" : "WireCanvasTests" + }, "testTimeoutsEnabled" : true }, "testTargets" : [ diff --git a/wire-ios-cryptobox/WireCryptoboxTests/TestPlans/AllTests.xctestplan b/wire-ios-cryptobox/WireCryptoboxTests/TestPlans/AllTests.xctestplan index b86e5d8f2c3..c4a0defe0c1 100644 --- a/wire-ios-cryptobox/WireCryptoboxTests/TestPlans/AllTests.xctestplan +++ b/wire-ios-cryptobox/WireCryptoboxTests/TestPlans/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireCryptobox.xcodeproj", + "identifier" : "BA7EF9681B7109B600204A8E", + "name" : "WireCryptoboxTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios-data-model/Tests/TestPlans/AllTests.xctestplan b/wire-ios-data-model/Tests/TestPlans/AllTests.xctestplan index c85785238f0..056c8315d90 100644 --- a/wire-ios-data-model/Tests/TestPlans/AllTests.xctestplan +++ b/wire-ios-data-model/Tests/TestPlans/AllTests.xctestplan @@ -14,6 +14,17 @@ "argument" : "-com.apple.CoreData.ConcurrencyDebug 1" } ], + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], + "targetForVariableExpansion" : { + "containerPath" : "container:WireDataModel.xcodeproj", + "identifier" : "F9C9A5051CAD5DF10039E10C", + "name" : "WireDataModelTests" + }, "testTimeoutsEnabled" : true }, "testTargets" : [ diff --git a/wire-ios-images/Tests/TestPlans/AllTests.xctestplan b/wire-ios-images/Tests/TestPlans/AllTests.xctestplan index 4c641750431..15732562d3b 100644 --- a/wire-ios-images/Tests/TestPlans/AllTests.xctestplan +++ b/wire-ios-images/Tests/TestPlans/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireImages.xcodeproj", + "identifier" : "096960151B663E7C006DF53B", + "name" : "WireImages-iosTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios-link-preview/WireLinkPreviewTests/TestPlans/AllTests.xctestplan b/wire-ios-link-preview/WireLinkPreviewTests/TestPlans/AllTests.xctestplan index 7d224149f52..cdf5419ad14 100644 --- a/wire-ios-link-preview/WireLinkPreviewTests/TestPlans/AllTests.xctestplan +++ b/wire-ios-link-preview/WireLinkPreviewTests/TestPlans/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireLinkPreview.xcodeproj", + "identifier" : "BFF057931D25434E004A2C29", + "name" : "WireLinkPreviewTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios-mocktransport/Tests/TestPlans/AllTests.xctestplan b/wire-ios-mocktransport/Tests/TestPlans/AllTests.xctestplan index d5b53937313..fd2bfa03021 100644 --- a/wire-ios-mocktransport/Tests/TestPlans/AllTests.xctestplan +++ b/wire-ios-mocktransport/Tests/TestPlans/AllTests.xctestplan @@ -14,8 +14,19 @@ "argument" : "-com.apple.CoreData.ConcurrencyDebug 1" } ], + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireMockTransport.xcodeproj", + "identifier" : "54C9023D1B7532DD007162A8", + "name" : "WireMockTransportTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios-notification-engine/Tests/TestPlans/AllTests.xctestplan b/wire-ios-notification-engine/Tests/TestPlans/AllTests.xctestplan index c01fbf7c5fd..f7a4c0cfab4 100644 --- a/wire-ios-notification-engine/Tests/TestPlans/AllTests.xctestplan +++ b/wire-ios-notification-engine/Tests/TestPlans/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireNotificationEngine.xcodeproj", + "identifier" : "EE761664299E60C9005DB75F", + "name" : "WireNotificationEngineTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios-protos/ProtosTests/TestPlans/AllTests.xctestplan b/wire-ios-protos/ProtosTests/TestPlans/AllTests.xctestplan index 7762dd9144e..e149c5f0941 100644 --- a/wire-ios-protos/ProtosTests/TestPlans/AllTests.xctestplan +++ b/wire-ios-protos/ProtosTests/TestPlans/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireProtos.xcodeproj", + "identifier" : "090838081B872DBF00629095", + "name" : "WireProtosTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios-request-strategy/Tests/TestPlans/AllTests.xctestplan b/wire-ios-request-strategy/Tests/TestPlans/AllTests.xctestplan index 6eb6d26d5f4..d9215875487 100644 --- a/wire-ios-request-strategy/Tests/TestPlans/AllTests.xctestplan +++ b/wire-ios-request-strategy/Tests/TestPlans/AllTests.xctestplan @@ -19,10 +19,19 @@ "enabled" : false, "key" : "LIBDISPATCH_COOPERATIVE_POOL_STRICT", "value" : "1" + }, + { + "key" : "CI", + "value" : "${CI}" } ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireRequestStrategy.xcodeproj", + "identifier" : "166901731D707509000FE4AF", + "name" : "WireRequestStrategyTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios-share-engine/Tests/TestPlans/AllTests.xctestplan b/wire-ios-share-engine/Tests/TestPlans/AllTests.xctestplan index 24112f9dbfe..ae652d5b91b 100644 --- a/wire-ios-share-engine/Tests/TestPlans/AllTests.xctestplan +++ b/wire-ios-share-engine/Tests/TestPlans/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireShareEngine.xcodeproj", + "identifier" : "5470D3F11D76E1B000FDE440", + "name" : "WireShareEngineTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios-sync-engine/Tests/TestsPlans/AllTests.xctestplan b/wire-ios-sync-engine/Tests/TestsPlans/AllTests.xctestplan index 33b06074abf..cfee8a150d1 100644 --- a/wire-ios-sync-engine/Tests/TestsPlans/AllTests.xctestplan +++ b/wire-ios-sync-engine/Tests/TestsPlans/AllTests.xctestplan @@ -33,6 +33,10 @@ "enabled" : false, "key" : "ZMLOG_TAGS", "value" : "MockTransportRequests" + }, + { + "key" : "CI", + "value" : "${CI}" } ], "targetForVariableExpansion" : { diff --git a/wire-ios-system/Tests/TestPlans/AllTests.xctestplan b/wire-ios-system/Tests/TestPlans/AllTests.xctestplan index 49625f077d0..ecea05d503c 100644 --- a/wire-ios-system/Tests/TestPlans/AllTests.xctestplan +++ b/wire-ios-system/Tests/TestPlans/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireSystem.xcodeproj", + "identifier" : "54A3272B1B99A3190004EB95", + "name" : "WireSystem Tests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios-testing/Tests/TestPlans/AllTests.xctestplan b/wire-ios-testing/Tests/TestPlans/AllTests.xctestplan index 7b686e86330..62b5fe3e46b 100644 --- a/wire-ios-testing/Tests/TestPlans/AllTests.xctestplan +++ b/wire-ios-testing/Tests/TestPlans/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireTesting.xcodeproj", + "identifier" : "096AD7C51B68D41D00E007A8", + "name" : "WireTesting-Tests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios-transport/Tests/TestPlans/AllTests.xctestplan b/wire-ios-transport/Tests/TestPlans/AllTests.xctestplan index 4d97aa1deaf..ad978cb47f8 100644 --- a/wire-ios-transport/Tests/TestPlans/AllTests.xctestplan +++ b/wire-ios-transport/Tests/TestPlans/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireTransport.xcodeproj", + "identifier" : "3E88BCB11B1F35DF00232589", + "name" : "WireTransport-ios-tests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios-utilities/Tests/TestPlans/AllTests.xctestplan b/wire-ios-utilities/Tests/TestPlans/AllTests.xctestplan index c3dcc5e86bf..07735358804 100644 --- a/wire-ios-utilities/Tests/TestPlans/AllTests.xctestplan +++ b/wire-ios-utilities/Tests/TestPlans/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:WireUtilities.xcodeproj", + "identifier" : "3E88BD421B1F3EA300232589", + "name" : "WireUtilities-Tests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios-ziphy/ZiphyTests/TestPlans/AllTests.xctestplan b/wire-ios-ziphy/ZiphyTests/TestPlans/AllTests.xctestplan index 5cb933a040c..ddf0a56cdb6 100644 --- a/wire-ios-ziphy/ZiphyTests/TestPlans/AllTests.xctestplan +++ b/wire-ios-ziphy/ZiphyTests/TestPlans/AllTests.xctestplan @@ -9,8 +9,19 @@ } ], "defaultOptions" : { + "environmentVariableEntries" : [ + { + "key" : "CI", + "value" : "${CI}" + } + ], "language" : "en", "region" : "DE", + "targetForVariableExpansion" : { + "containerPath" : "container:Ziphy.xcodeproj", + "identifier" : "DBF380631B15C0B800369FB7", + "name" : "ZiphyTests" + }, "testExecutionOrdering" : "random" }, "testTargets" : [ diff --git a/wire-ios/Tests/TestPlans/AllTests.xctestplan b/wire-ios/Tests/TestPlans/AllTests.xctestplan index 4b19645e92c..16323b07b70 100644 --- a/wire-ios/Tests/TestPlans/AllTests.xctestplan +++ b/wire-ios/Tests/TestPlans/AllTests.xctestplan @@ -23,6 +23,10 @@ "key" : "SNAPSHOT_REFERENCE_DIR", "value" : "$(SOURCE_ROOT)\/$(PROJECT_NAME) Tests\/ReferenceImages" }, + { + "key" : "CI", + "value" : "${CI}" + }, { "key" : "IMAGE_DIFF_DIR", "value" : "$(SOURCE_ROOT)\/SnapshotResults"