Created
June 12, 2015 15:15
-
-
Save josephjaniga/87639267eef9ded96fd1 to your computer and use it in GitHub Desktop.
Process.Exit(); Failure and Success Codes - SImulate Automation Result Codes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 0 1 2 | |
// node test.js # | |
var input = process.argv[2] || 1; | |
process.on('exit', function(code){ | |
if ( code == 0 ){ | |
console.log("success"); | |
} else { | |
console.log("failure"); | |
} | |
}); | |
process.exit(input); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment