spec: setImmediate should work in forked scripts

This commit is contained in:
Cheng Zhao 2015-09-17 15:12:15 +08:00
parent e30dd943db
commit 93639a080c
2 changed files with 18 additions and 0 deletions

11
spec/fixtures/module/set-immediate.js vendored Normal file
View file

@ -0,0 +1,11 @@
process.on('uncaughtException', function(error) {
process.send(error.message);
process.exit(1);
});
process.on('message', function(msg) {
setImmediate(function() {
process.send('ok');
process.exit(0);
});
});