Upgrade TypeScript to 3.5.1 (#2437)

This commit is contained in:
Kitson Kelly 2019-06-02 01:13:36 +10:00 committed by Ryan Dahl
parent 79f770b178
commit d438a6d259
9 changed files with 30 additions and 26 deletions

View file

@ -3,6 +3,12 @@
import "./unit_tests.ts";
import { permissionCombinations, parseUnitTestOutput } from "./test_util.ts";
interface TestResult {
perms: string;
output: string;
result: number;
}
function permsToCliFlags(perms: Deno.Permissions): string[] {
return Object.keys(perms)
.map(
@ -39,7 +45,7 @@ async function main(): Promise<void> {
console.log("\t" + fmtPerms(perms));
}
const testResults = new Set();
const testResults = new Set<TestResult>();
for (const perms of permissionCombinations.values()) {
const permsFmt = fmtPerms(perms);
@ -84,10 +90,10 @@ async function main(): Promise<void> {
// run should fail
let testsFailed = false;
for (const testResult of testResults.values()) {
for (const testResult of testResults) {
console.log(`Summary for ${testResult.perms}`);
console.log(testResult.output + "\n");
testsFailed = testsFailed || testResult.result;
testsFailed = testsFailed || Boolean(testResult.result);
}
if (testsFailed) {