Files
trezor-suite/ci/scripts/check-vulnerabilities.js
martin ce6362c41a add lighthouse security audits test (#943)
* add lighthouse security audits test

* ah, add build

* re-enable all
2019-12-16 12:20:18 +01:00

19 lines
390 B
JavaScript

var stdin = process.openStdin();
var data = "";
stdin.on('data', function(chunk) {
data += chunk;
});
stdin.on('end', function() {
console.log(data);
const index = data.indexOf("] Total");
if (data[index-1] === '0') return process.exit(0);
return process.exit(1);
});
process.on('exit', function(code) {
return console.log(`Security check exited with code ${code}`);
});