Fallback to downloading from go.dev/dl instead of storage.googleapis.com/golang (v4) (#690)

* fallback download url update

* license update

* license update

* license updates

* updates
This commit is contained in:
aparnajyothi-y
2025-12-15 23:00:28 +05:30
committed by GitHub
parent 19bb51245e
commit 7b8cf10d4e
25 changed files with 3279 additions and 416 deletions

View File

@@ -368,7 +368,7 @@ describe('setup-go', () => {
const expPath = path.win32.join(toolPath, 'bin');
expect(dlSpy).toHaveBeenCalledWith(
'https://storage.googleapis.com/golang/go1.13.1.windows-amd64.zip',
'https://go.dev/dl/go1.13.1.windows-amd64.zip',
'C:\\temp\\go1.13.1.windows-amd64.zip',
undefined
);
@@ -922,7 +922,7 @@ use .
const expectedUrl =
platform === 'win32'
? `https://github.com/actions/go-versions/releases/download/${version}/go-${version}-${platform}-${arch}.${fileExtension}`
: `https://storage.googleapis.com/golang/go${version}.${osSpec}-${arch}.${fileExtension}`;
: `https://go.dev/dl/go${version}.${osSpec}-${arch}.${fileExtension}`;
// ... but not in the local cache
findSpy.mockImplementation(() => '');