fix tslint errors

This commit is contained in:
Alex Kalyvitis 2020-06-18 18:29:25 +02:00
parent ff8fe44e0c
commit 3ff198f23b
6 changed files with 39 additions and 35 deletions

View file

@ -1,7 +1,4 @@
"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
var __importStar = (this && this.__importStar) || function (mod) {
if (mod && mod.__esModule) return mod;
var result = {};
@ -9,13 +6,16 @@ var __importStar = (this && this.__importStar) || function (mod) {
result["default"] = mod;
return result;
};
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const ava_1 = __importDefault(require("ava"));
const path = __importStar(require("path"));
const toolcache = __importStar(require("@actions/tool-cache"));
const util = __importStar(require("./util"));
const ava_1 = __importDefault(require("ava"));
const nock_1 = __importDefault(require("nock"));
const path = __importStar(require("path"));
const setupTools = __importStar(require("./setup-tools"));
const util = __importStar(require("./util"));
ava_1.default('download codeql bundle cache', async (t) => {
await util.withTmpDir(async (tmpDir) => {
process.env['GITHUB_WORKSPACE'] = tmpDir;
@ -45,14 +45,16 @@ ava_1.default('parse codeql bundle url version', t => {
'1.2.3-beta.1': '1.2.3-beta.1',
};
for (const version in tests) {
const expectedVersion = tests[version];
const url = `https://github.com/.../codeql-bundle-${version}/...`;
try {
const parsedVersion = setupTools.getCodeQLURLVersion(url);
t.assert(parsedVersion, expectedVersion);
}
catch (e) {
t.fail(e.message);
if (tests.hasOwnProperty(version)) {
const expectedVersion = tests[version];
const url = `https://github.com/.../codeql-bundle-${version}/...`;
try {
const parsedVersion = setupTools.getCodeQLURLVersion(url);
t.assert(parsedVersion, expectedVersion);
}
catch (e) {
t.fail(e.message);
}
}
}
});