mirror of
https://github.com/actions/setup-go.git
synced 2025-06-29 20:53:43 +00:00
Adding tests (#2)
* add tests * fixing tests * change names of it * resolve comments Co-authored-by: Dmitry Shibanov <v-dmshib@microsoft.com>
This commit is contained in:
parent
ddc76880cc
commit
60dce67d9a
4 changed files with 205 additions and 59 deletions
5
dist/index.js
vendored
5
dist/index.js
vendored
|
@ -4899,7 +4899,7 @@ module.exports = require("fs");
|
|||
/***/ }),
|
||||
|
||||
/***/ 749:
|
||||
/***/ (function(__unusedmodule, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
@ -4990,6 +4990,7 @@ function getGo(versionSpec, stable, auth) {
|
|||
throw new Error(`Unable to find Go version '${versionSpec}' for platform ${osPlat} and architecture ${osArch}.`);
|
||||
}
|
||||
try {
|
||||
console.log("Install from dist");
|
||||
downloadPath = yield installGoVersion(info, undefined);
|
||||
}
|
||||
catch (err) {
|
||||
|
@ -5067,7 +5068,7 @@ function findMatch(versionSpec, stable) {
|
|||
let result;
|
||||
let match;
|
||||
const dlUrl = 'https://golang.org/dl/?mode=json&include=all';
|
||||
let candidates = yield getVersionsDist(dlUrl);
|
||||
let candidates = yield module.exports.getVersionsDist(dlUrl);
|
||||
if (!candidates) {
|
||||
throw new Error(`golang download url did not return results`);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue