Skip to content

Commit

Permalink
fix: enhance smoke test debuggability by adding --stacktrace flag t…
Browse files Browse the repository at this point in the history
…o inner Gradle runner
  • Loading branch information
ianbotsf committed Jan 29, 2025
1 parent 3d084dc commit 89cbcd0
Showing 1 changed file with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ import aws.sdk.kotlin.codegen.smoketests.AWS_SERVICE_FILTER
import aws.sdk.kotlin.codegen.smoketests.AWS_SKIP_TAGS
import org.gradle.testkit.runner.GradleRunner
import java.io.File
import kotlin.test.*
import kotlin.test.Test
import kotlin.test.assertContains

class SmokeTestE2ETest {
@Test
Expand Down Expand Up @@ -65,8 +66,11 @@ private fun runSmokeTests(

val task = GradleRunner.create()
.withProjectDir(File(sdkRootDir))
// FIXME: Remove `-Paws.kotlin.native=false` when Kotlin Native is ready
.withArguments("-Paws.kotlin.native=false", ":tests:codegen:smoke-tests:services:$service:smokeTest")
.withArguments(
"--stacktrace", // Make sure unexpected errors are debuggable
"-Paws.kotlin.native=false", // FIXME: Remove `-Paws.kotlin.native=false` when Kotlin Native is ready
":tests:codegen:smoke-tests:services:$service:smokeTest",
)
.withEnvironment(envVars)

val buildResult = if (expectingFailure) task.buildAndFail() else task.build()
Expand Down

0 comments on commit 89cbcd0

Please sign in to comment.