diff --git a/.teamcity/components/service_build_config.kt b/.teamcity/components/service_build_config.kt index 09f6130ce03..bb65754bd1d 100644 --- a/.teamcity/components/service_build_config.kt +++ b/.teamcity/components/service_build_config.kt @@ -1,4 +1,5 @@ import jetbrains.buildServer.configs.kotlin.AbsoluteId +import jetbrains.buildServer.configs.kotlin.BuildSteps import jetbrains.buildServer.configs.kotlin.BuildType import jetbrains.buildServer.configs.kotlin.DslContext import jetbrains.buildServer.configs.kotlin.ParameterDisplay @@ -53,7 +54,7 @@ class Service(name: String, spec: ServiceSpec) { val serviceDir = "./internal/service/$packageName" steps { - configureGoEnv() + ConfigureGoEnv() script { name = "Compile Test Binary" workingDir = serviceDir @@ -104,9 +105,9 @@ class Service(name: String, spec: ServiceSpec) { } } -fun configureGoEnv(): ScriptBuildStep { - return ScriptBuildStep { +fun BuildSteps.ConfigureGoEnv() { + step(ScriptBuildStep { name = "Configure GOENV" scriptContent = File("./scripts/configure_goenv.sh").readText() - } + }) } diff --git a/.teamcity/settings.kts b/.teamcity/settings.kts index cca50c5c77a..d7c3f8f530f 100644 --- a/.teamcity/settings.kts +++ b/.teamcity/settings.kts @@ -142,7 +142,7 @@ object PullRequest : BuildType({ val accTestRoleARN = DslContext.getParameter("aws_account.role_arn", "") steps { - configureGoEnv() + ConfigureGoEnv() script { name = "Run Tests" scriptContent = File("./scripts/pullrequest_tests/tests.sh").readText() @@ -304,7 +304,7 @@ object SetUp : BuildType({ } steps { - configureGoEnv() + ConfigureGoEnv() script { name = "Run provider unit tests" scriptContent = File("./scripts/provider_tests/unit_tests.sh").readText() @@ -397,7 +397,7 @@ object CleanUp : BuildType({ } steps { - configureGoEnv() + ConfigureGoEnv() script { name = "Post-Sweeper" enabled = false @@ -416,7 +416,7 @@ object Sweeper : BuildType({ } steps { - configureGoEnv() + ConfigureGoEnv() script { name = "Sweeper" scriptContent = File("./scripts/sweeper.sh").readText()