var assert = require('assert');
var exec = require('../').exec;
var spawn = require('../').spawn;

exec('echo hello')
    .then(function (result) {
        var stdout = result.stdout;
        var stderr = result.stderr;

        assert.equal(stdout.toString(), 'hello\n');
        assert.equal(stderr.toString(), '');
    })
    .fail(function (err) {
        console.error("ERROR: ", (err.stack || err));
    })
    .progress(function (childProcess) {
        console.log('[exec] childProcess.pid: ', childProcess.pid);
    });

var spawnErr = '';

spawn('echo', ['hello'])
    .progress(function (childProcess) {
        console.log('[spawn] childProcess.pid: ', childProcess.pid);
        childProcess.stderr.on('data', function (data) {
            spawnErr += data;
        });
    })
    .then(function (result) {
        assert.equal(result.toString(), 'hello\n');
        assert.equal(spawnErr.toString(), '');
    })
    .fail(function (err) {
        console.error("ERROR: ", (err.stack || err));
    });

@@ -33,45 +33,10 @@
 var 
-exec = require('../').exec;%0Avar spawn
+cp
  = r
@@ -52,17 +52,14 @@
 ./')
-.spawn
 ;%0A%0A
+cp.
 exec
@@ -485,16 +485,463 @@
    %7D);%0A%0A
+cp.execFile('echo', %5B'hello'%5D)%0A    .then(function (result) %7B%0A        var stdout = result.stdout;%0A        var stderr = result.stderr;%0A%0A        assert.equal(stdout.toString(), 'hello%5Cn');%0A        assert.equal(stderr.toString(), '');%0A    %7D)%0A    .fail(function (err) %7B%0A        console.error(%22ERROR: %22, (err.stack %7C%7C err));%0A    %7D)%0A    .progress(function (childProcess) %7B%0A        console.log('%5BexecFile%5D childProcess.pid: ', childProcess.pid);%0A    %7D);%0A%0A
 var spaw
@@ -952,16 +952,19 @@
  = '';%0A%0A
+cp.
 spawn('e

Update test