Skip to content

Commit

Permalink
Fix the MoTTool to catch an exception (#4934)
Browse files Browse the repository at this point in the history
  • Loading branch information
sarangan12 authored Dec 17, 2018
1 parent 92a9287 commit a87e466
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion scripts/momentOfTruth.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ async function getLinterResult(swaggerPath) {
console.log(`An error occurred while executing JSON.parse() on the linter output for ${swaggerPath}:`);
console.dir(resultString);
console.dir(e, { depth: null, colors: true });
process.exit(1)
}
}
return [];
Expand All @@ -87,7 +88,7 @@ async function getLinterResult(swaggerPath) {
async function runTools(swagger, beforeOrAfter) {
console.log(`Processing "${swagger}":`);
const linterErrors = await getLinterResult(swagger);
console.log(`Linter produced ${linterErrors.length} results`);
console.log(linterErrors);
await updateResult(swagger, linterErrors, beforeOrAfter);
};

Expand Down
1 change: 1 addition & 0 deletions scripts/momentOfTruthPostProcessing.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ try {
console.log(`Failed to read diff results from file ${logFilepath}`);
console.log("File content:");
console.log(data);
process.exit(1)
}

function compareJsonRef(beforeJsonRef, afterJsonRef) {
Expand Down

0 comments on commit a87e466

Please sign in to comment.