]> khamidou — GitHub mirrors - electron.git/commitdiff
Make child_process.fork work when options.env is set.
authorCheng Zhao <zcbenz@gmail.com>
Thu, 5 Sep 2013 01:47:32 +0000 (09:47 +0800)
committerCheng Zhao <zcbenz@gmail.com>
Thu, 5 Sep 2013 01:47:32 +0000 (09:47 +0800)
spec/node/child_process.coffee
vendor/node

index fdffb1058abb29d6c75d6a2aba9a908b32f3b6b4..6d0c1dbe5e95cb70f39ad66cbfbf81e8ea4312f1 100644 (file)
@@ -19,3 +19,12 @@ describe 'child_process', ->
         assert.equal msg, 'message'
         done()
       child.send 'message'
+
+    it 'should work in forked process when options.env is specifed', (done) ->
+      child = child_process.fork path.join(fixtures, 'module', 'fork_ping.js'),
+                                 [],
+                                 env: {test: 'somevar'}
+      child.on 'message', (msg) ->
+        assert.equal msg, 'message'
+        done()
+      child.send 'message'
index 9fc97854c9395edea096464edfb1e0a3b68145fe..c2ecf615ac2bb846a38ffa0b64e9ce0ff4f8953b 160000 (submodule)
@@ -1 +1 @@
-Subproject commit 9fc97854c9395edea096464edfb1e0a3b68145fe
+Subproject commit c2ecf615ac2bb846a38ffa0b64e9ce0ff4f8953b