Skip to content

Commit

Permalink
add integ test and fix ktlint
Browse files Browse the repository at this point in the history
  • Loading branch information
dayaffe committed Nov 5, 2024
1 parent d711bc5 commit 1078672
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
12 changes: 12 additions & 0 deletions IntegrationTests/Services/AWSSQSIntegrationTests/SQSTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,16 @@ class SQSTests: XCTestCase {
XCTAssertNotNil(response.queueUrl, "Queue URL should not be nil")
XCTAssertTrue(response.queueUrl?.contains(queueName) ?? false, "Queue URL should contain the queue name.")
}

func test_QueryCompatible() async throws {
do {
let response = try await client.getQueueUrl(input: .init(queueName: "non-existent-queue-123"))

Check warning on line 47 in IntegrationTests/Services/AWSSQSIntegrationTests/SQSTests.swift

View workflow job for this annotation

GitHub Actions / apple (macos-15, Xcode_16.1, platform=tvOS Simulator,OS=18.1,name=Apple TV 4K (3rd generation) (a...

initialization of immutable value 'response' was never used; consider replacing with assignment to '_' or removing it

Check warning on line 47 in IntegrationTests/Services/AWSSQSIntegrationTests/SQSTests.swift

View workflow job for this annotation

GitHub Actions / apple (macos-15, Xcode_16.1, platform=macOS)

initialization of immutable value 'response' was never used; consider replacing with assignment to '_' or removing it

Check warning on line 47 in IntegrationTests/Services/AWSSQSIntegrationTests/SQSTests.swift

View workflow job for this annotation

GitHub Actions / apple (macos-15, Xcode_16.1, platform=visionOS Simulator,OS=2.1,name=Apple Vision Pro)

initialization of immutable value 'response' was never used; consider replacing with assignment to '_' or removing it

Check warning on line 47 in IntegrationTests/Services/AWSSQSIntegrationTests/SQSTests.swift

View workflow job for this annotation

GitHub Actions / apple (macos-15, Xcode_16.1, platform=iOS Simulator,OS=18.1,name=iPhone 16)

initialization of immutable value 'response' was never used; consider replacing with assignment to '_' or removing it

Check warning on line 47 in IntegrationTests/Services/AWSSQSIntegrationTests/SQSTests.swift

View workflow job for this annotation

GitHub Actions / apple (macos-14, Xcode_15.2, platform=iOS Simulator,OS=17.2,name=iPhone 15)

initialization of immutable value 'response' was never used; consider replacing with assignment to '_' or removing it

Check warning on line 47 in IntegrationTests/Services/AWSSQSIntegrationTests/SQSTests.swift

View workflow job for this annotation

GitHub Actions / apple (macos-14, Xcode_15.2, platform=macOS)

initialization of immutable value 'response' was never used; consider replacing with assignment to '_' or removing it

Check warning on line 47 in IntegrationTests/Services/AWSSQSIntegrationTests/SQSTests.swift

View workflow job for this annotation

GitHub Actions / apple (macos-14, Xcode_15.2, platform=tvOS Simulator,OS=17.2,name=Apple TV 4K (3rd generation) (a...

initialization of immutable value 'response' was never used; consider replacing with assignment to '_' or removing it

Check warning on line 47 in IntegrationTests/Services/AWSSQSIntegrationTests/SQSTests.swift

View workflow job for this annotation

GitHub Actions / apple (macos-14, Xcode_15.2, platform=visionOS Simulator,OS=1.0,name=Apple Vision Pro)

initialization of immutable value 'response' was never used; consider replacing with assignment to '_' or removing it
XCTFail("Expected an error to be thrown!")
} catch let error as QueueDoesNotExist {
let errorCode = error.errorCode
XCTAssertTrue(errorCode == "AWS.SimpleQueueService.NonExistentQueue")
} catch let unknownError {
XCTFail("An unexpected error occurred: \(unknownError.localizedDescription)")
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,4 @@ class AwsQueryModeCustomization : SwiftIntegration {
) {
operationMiddleware.appendMiddleware(operationShape, awsQueryModeHeaderMiddleware)
}
}
}

0 comments on commit 1078672

Please sign in to comment.