mirror of
https://github.com/nodejs/node.git
synced 2026-11-09 15:11:11 -05:00
Add failing uncaughtException test
FIXME
This commit is contained in:
1 parent
e49be4768b
commit
635986e433
1 file changed
+11
@@ -0,0 +1,11 @@
|
||||
process.on('uncaughtException', function (err) {
|
||||
console.log('Caught exception: ' + err);
|
||||
});
|
||||
|
||||
setTimeout(function () {
|
||||
console.log('This will still run.');
|
||||
}, 500);
|
||||
|
||||
// Intentionally cause an exception, but don't catch it.
|
||||
nonexistentFunc();
|
||||
console.log('This will not run.');
|
||||
Reference in new issue
Block a user