Merge pull request #9132 from electron/fork-eval-node-fix
Cherry pick node fix for ChildProcess.fork --eval bug
This commit is contained in:
commit
e3407bb99e
2 changed files with 11 additions and 1 deletions
|
@ -91,6 +91,16 @@ describe('node feature', function () {
|
||||||
done()
|
done()
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
|
it('works when sending a message to a process forked with the --eval argument', function (done) {
|
||||||
|
const source = "process.on('message', (message) => { process.send(message) })"
|
||||||
|
const forked = ChildProcess.fork('--eval', [source])
|
||||||
|
forked.once('message', (message) => {
|
||||||
|
assert.equal(message, 'hello')
|
||||||
|
done()
|
||||||
|
})
|
||||||
|
forked.send('hello')
|
||||||
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
describe('child_process.spawn', function () {
|
describe('child_process.spawn', function () {
|
||||||
|
|
2
vendor/node
vendored
2
vendor/node
vendored
|
@ -1 +1 @@
|
||||||
Subproject commit a6663598aa78832e7955cb93c51a098eac787abb
|
Subproject commit 3fe90cfcf54dd946980e59daf550a7cdb2317c8f
|
Loading…
Add table
Add a link
Reference in a new issue