mirror of https://github.com/lukechilds/node.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
483 B
22 lines
483 B
15 years ago
|
process.mixin(require("./common"));
|
||
|
|
||
|
var sub = path.join(fixturesDir, 'echo.js');
|
||
|
|
||
|
var result = false;
|
||
|
|
||
|
var child = process.createChildProcess(path.join(libDir, "../bin/node"), [sub]);
|
||
|
child.addListener("error", function (data){
|
||
|
puts("parent stderr: " + data);
|
||
|
});
|
||
|
child.addListener("output", function (data){
|
||
|
if (data && data[0] == 't') {
|
||
|
result = true;
|
||
|
}
|
||
|
});
|
||
|
setTimeout(function () {
|
||
|
child.write('t\r\n');
|
||
|
}, 100);
|
||
|
setTimeout(function (){
|
||
|
assert.ok(result);
|
||
|
}, 500)
|