Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion IntegrationTests/Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ let package = Package(
dependencies: [
.package(path: "../../smithy-swift"),
.package(path: "../../aws-sdk-swift"),
.package(url: "https://github.com/smithy-lang/smithy-swift-opentelemetry.git", from: "1.0.0"),
.package(url: "https://github.com/open-telemetry/opentelemetry-swift.git", from: "1.13.0"),
],
targets: integrationTestTargets
)
Expand Down Expand Up @@ -71,6 +73,7 @@ private func integrationTestTarget(_ name: String) -> Target {
let integrationTestName = "\(name)IntegrationTests"
var additionalDependencies: [String] = []
var exclusions: [String] = []
var platformSpecificDependencies: [Target.Dependency] = []
switch name {
case "AWSEC2":
additionalDependencies = ["AWSIAM", "AWSSTS", "AWSCloudWatchLogs"]
Expand All @@ -93,6 +96,10 @@ private func integrationTestTarget(_ name: String) -> Target {
additionalDependencies = ["AWSCloudFront"]
case "AWSSTS":
additionalDependencies = ["AWSIAM", "AWSCognitoIdentity"]
platformSpecificDependencies = [
.product(name: "SmithyOpenTelemetry", package: "smithy-swift-opentelemetry", condition: .when(platforms: [.macOS, .iOS, .tvOS, .watchOS])),
.product(name: "InMemoryExporter", package: "opentelemetry-swift", condition: .when(platforms: [.macOS, .iOS, .tvOS, .watchOS]))
]
case "AWSCognitoIdentity":
additionalDependencies = ["AWSSTS", "AWSIAM"]
default:
Expand All @@ -113,7 +120,7 @@ private func integrationTestTarget(_ name: String) -> Target {
.product(name: name, package: "aws-sdk-swift")
] + additionalDependencies.map {
Target.Dependency.product(name: $0, package: "aws-sdk-swift", condition: nil)
},
} + platformSpecificDependencies,
path: "./Services/\(integrationTestName)",
exclude: exclusions,
resources: [.process("Resources")]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,10 @@ import AWSSTS
import AWSIAM
import AWSSDKIdentity
import ClientRuntime
#if canImport(InMemoryExporter)
#if os(macOS) || os(iOS) || os(watchOS) || os(tvOS)
import SmithyOpenTelemetry
import InMemoryExporter
#endif
//#if os(Linux)
//import OpenTelemetryConcurrency
//#endif

class STSAssumeRoleAWSCredentialIdentityResolverTests: XCTestCase {
private let region = "us-east-1"
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,4 @@ This library is licensed under the Apache 2.0 License.

## Security

Please refer to our [security policy](https://github.com/awslabs/aws-sdk-swift/security/policy).
Please refer to our [security policy](https://github.com/awslabs/aws-sdk-swift/security/policy).
Loading