dot-notation

This commit is contained in:
Alexander T 2019-06-14 10:44:19 +03:00
parent 8896c676be
commit 550a99e839
4 changed files with 6 additions and 6 deletions

View file

@ -67,7 +67,7 @@
"complexity": "off",
"constructor-super": "error",
"curly": ["error", "multi-line"],
"dot-notation": "off",
"dot-notation": "error",
"eol-last": "off",
"eqeqeq": "error",
"guard-for-in": "off",

View file

@ -169,7 +169,7 @@ var args = process.argv.slice(2);
if (args.length < 1) {
console.log('Usage: node authors.js [command]');
console.log('List of commands: ');
Object.keys(Commands).forEach(k => console.log(` ${k}: ${(Commands as any)[k]['description']}`));
Object.keys(Commands).forEach(k => console.log(` ${k}: ${(Commands as any)[k].description}`));
} else {
var cmd: Function = (Commands as any)[args[0]];
if (cmd === undefined) {

View file

@ -13,7 +13,7 @@ fs.readFile('src/compiler/diagnosticMessages.json', 'utf-8', (err, data) => {
console.log('Loaded ' + keys.length + ' errors');
for (let k of keys) {
messages[k]['seen'] = false;
messages[k].seen = false;
}
let errRegex = /\(\d+,\d+\): error TS([^:]+):/g;
@ -30,7 +30,7 @@ fs.readFile('src/compiler/diagnosticMessages.json', 'utf-8', (err, data) => {
while (g = errRegex.exec(baseline)) {
var errCode = +g[1];
let msg = keys.filter(k => messages[k].code === errCode)[0];
messages[msg]['seen'] = true;
messages[msg].seen = true;
}
done();
@ -41,7 +41,7 @@ fs.readFile('src/compiler/diagnosticMessages.json', 'utf-8', (err, data) => {
console.log('== List of errors not present in baselines ==');
let count = 0;
for (let k of keys) {
if (messages[k]['seen'] !== true) {
if (messages[k].seen !== true) {
console.log(k);
count++;
}

View file

@ -53,7 +53,7 @@ function importDefinitelyTypedTest(tscPath: string, rwcTestPath: string, testCas
}
let testDirectoryName = testCaseName + "_" + Math.floor((Math.random() * 10000) + 1);
let testDirectoryPath = path.join(process.env["temp"], testDirectoryName);
let testDirectoryPath = path.join(process.env.temp, testDirectoryName);
if (fs.existsSync(testDirectoryPath)) {
throw new Error("Could not create test directory");
}