Skip to content

Commit d9fb5bd

Browse files
Merge branch 'main' into copilot/testify-expert-improve-test-quality
2 parents 96f643d + 9866d47 commit d9fb5bd

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

pkg/workflow/compiler_yaml_main_job.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,10 +233,12 @@ func (c *Compiler) generateRuntimeAndWorkspaceSetupSteps(yaml *strings.Builder,
233233
// This step must run before any runtime setup steps (setup-go, setup-node, etc.) so that
234234
// those actions pick up the redirected path when they write into RUNNER_TOOL_CACHE.
235235
if isArcDindTopology(data) {
236-
yaml.WriteString(" - name: Redirect tool cache for ARC/DinD\n")
236+
yaml.WriteString(" - name: Redirect tool cache and install paths for ARC/DinD\n")
237237
yaml.WriteString(" run: |\n")
238238
yaml.WriteString(" mkdir -p \"${RUNNER_TEMP}/gh-aw/tool-cache\"\n")
239239
yaml.WriteString(" echo \"RUNNER_TOOL_CACHE=${RUNNER_TEMP}/gh-aw/tool-cache\" >> \"$GITHUB_ENV\"\n")
240+
yaml.WriteString(" echo \"DOTNET_INSTALL_DIR=${RUNNER_TEMP}/gh-aw/tool-cache/dotnet\" >> \"$GITHUB_ENV\"\n")
241+
yaml.WriteString(" echo \"GOPATH=${RUNNER_TEMP}/gh-aw/tool-cache/go\" >> \"$GITHUB_ENV\"\n")
240242
}
241243

242244
if needsCheckout || !customStepsContainCheckout {

pkg/workflow/compiler_yaml_main_job_test.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -748,9 +748,11 @@ func TestGenerateMainJobStepsArcDindRedirectsToolCacheToRunnerTemp(t *testing.T)
748748
require.NoError(t, err)
749749

750750
result := yaml.String()
751-
assert.Contains(t, result, "- name: Redirect tool cache for ARC/DinD")
751+
assert.Contains(t, result, "- name: Redirect tool cache and install paths for ARC/DinD")
752752
assert.Contains(t, result, `mkdir -p "${RUNNER_TEMP}/gh-aw/tool-cache"`)
753753
assert.Contains(t, result, `echo "RUNNER_TOOL_CACHE=${RUNNER_TEMP}/gh-aw/tool-cache" >> "$GITHUB_ENV"`)
754+
assert.Contains(t, result, `echo "DOTNET_INSTALL_DIR=${RUNNER_TEMP}/gh-aw/tool-cache/dotnet" >> "$GITHUB_ENV"`)
755+
assert.Contains(t, result, `echo "GOPATH=${RUNNER_TEMP}/gh-aw/tool-cache/go" >> "$GITHUB_ENV"`)
754756
assert.NotContains(t, result, "/tmp/gh-aw/tool-cache")
755757
}
756758

0 commit comments

Comments
 (0)