mirror of
https://github.com/nodejs/node.git
synced 2024-11-25 08:19:38 +01:00
3e1b1dd4a9
The copyright and license notice is already in the LICENSE file. There is no justifiable reason to also require that it be included in every file, since the individual files are not individually distributed except as part of the entire package.
27 lines
639 B
JavaScript
27 lines
639 B
JavaScript
require('../common');
|
|
var util = require('util');
|
|
var assert = require('assert');
|
|
var exec = require('child_process').exec;
|
|
|
|
var success_count = 0;
|
|
var error_count = 0;
|
|
|
|
var cmd = [process.execPath, '-e', '"console.error(process.argv)"',
|
|
'foo', 'bar'].join(' ');
|
|
var expected = util.format([process.execPath, 'foo', 'bar']) + '\n';
|
|
var child = exec(cmd, function(err, stdout, stderr) {
|
|
if (err) {
|
|
console.log(err.toString());
|
|
++error_count;
|
|
return;
|
|
}
|
|
assert.equal(stderr, expected);
|
|
++success_count;
|
|
});
|
|
|
|
process.on('exit', function() {
|
|
assert.equal(1, success_count);
|
|
assert.equal(0, error_count);
|
|
});
|
|
|