Skip to content

Commit

Permalink
ktlintFormat
Browse files Browse the repository at this point in the history
  • Loading branch information
lauzadis committed Oct 6, 2023
1 parent 6234df5 commit ee15721
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public class ClockSkewInterceptor : HttpInterceptor {
val logger = coroutineContext.logger<ClockSkewInterceptor>()

if (currentSkew != Duration.ZERO) {
logger.info { "applying clock skew $currentSkew to client"}
logger.info { "applying clock skew $currentSkew to client" }
context.executionContext[HttpOperationContext.ClockSkew] = currentSkew
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ import aws.smithy.kotlin.runtime.http.interceptors.ClockSkewInterceptor.Companio
import aws.smithy.kotlin.runtime.http.interceptors.ClockSkewInterceptor.Companion.getSkew
import aws.smithy.kotlin.runtime.http.interceptors.ClockSkewInterceptor.Companion.isSkewed
import aws.smithy.kotlin.runtime.http.operation.HttpOperationContext
import aws.smithy.kotlin.runtime.http.request.HttpRequestBuilder
import aws.smithy.kotlin.runtime.http.operation.newTestOperation
import aws.smithy.kotlin.runtime.http.operation.roundTrip
import aws.smithy.kotlin.runtime.http.request.HttpRequestBuilder
import aws.smithy.kotlin.runtime.http.response.HttpResponse
import aws.smithy.kotlin.runtime.httptest.TestEngine
import aws.smithy.kotlin.runtime.io.SdkSource
Expand Down Expand Up @@ -69,9 +69,12 @@ class ClockSkewInterceptorTest {
val clientTimeString = "20231006T131604Z"
val clientTime = Instant.fromIso8601(clientTimeString)

val client = getMockClient("bla".encodeToByteArray(), Headers {
append("Date", serverTimeString)
})
val client = getMockClient(
"bla".encodeToByteArray(),
Headers {
append("Date", serverTimeString)
},
)

val req = HttpRequestBuilder().apply {
body = ByteArrayContent("<Foo>bar</Foo>".encodeToByteArray())
Expand All @@ -93,9 +96,12 @@ class ClockSkewInterceptorTest {
val serverTimeString = "Wed, 06 Oct 2023 13:16:04 -0000"
val clientTimeString = "20231006T131604Z"

val client = getMockClient("bla".encodeToByteArray(), Headers {
append("Date", serverTimeString)
})
val client = getMockClient(
"bla".encodeToByteArray(),
Headers {
append("Date", serverTimeString)
},
)

val req = HttpRequestBuilder().apply {
body = ByteArrayContent("<Foo>bar</Foo>".encodeToByteArray())
Expand Down

0 comments on commit ee15721

Please sign in to comment.