3
0
Fork 0
mirror of https://gitea.com/actions/setup-go.git synced 2024-11-22 01:29:32 +01:00

Fix formatting

This commit is contained in:
Josh Gross 2022-03-14 12:23:03 -04:00
parent 2a34c33bd7
commit 802876f7c7
No known key found for this signature in database
GPG key ID: 17A6308EA2144978
2 changed files with 4 additions and 5 deletions

View file

@ -240,7 +240,7 @@ describe('setup-go', () => {
let toolPath = path.normalize('/cache/go/1.13.0/x64');
findSpy.mockImplementation(() => toolPath);
let vars: { [key: string]: string; } = {};
let vars: {[key: string]: string} = {};
exportVarSpy.mockImplementation((name: string, val: string) => {
vars[name] = val;
});
@ -256,18 +256,17 @@ describe('setup-go', () => {
let toolPath = path.normalize('/cache/go/1.8.0/x64');
findSpy.mockImplementation(() => toolPath);
let vars: { [key: string]: string; } = {};
let vars: {[key: string]: string} = {};
exportVarSpy.mockImplementation((name: string, val: string) => {
vars[name] = val;
});
await main.run();
expect(vars).toStrictEqual({
"GOROOT": toolPath
GOROOT: toolPath
});
});
it('finds a version of go already in the cache', async () => {
inputs['go-version'] = '1.13.0';

View file

@ -30,7 +30,7 @@ export async function run() {
const version = installer.makeSemver(versionSpec);
// Go versions less than 1.9 require GOROOT to be set
if (semver.lt(version, '1.9.0')) {
core.info("Setting GOROOT for Go version < 1.9");
core.info('Setting GOROOT for Go version < 1.9');
core.exportVariable('GOROOT', installDir);
}