mirror of
https://github.com/nodejs/node.git
synced 2024-12-01 16:10:02 +01:00
f76722686b
The test wasn't checking directly that an assertion was thrown. Instead,
it was checking that spawn did not sucessfully spawn a non-existent
command.
However, the command chosen, dir, exists in GNU coreutils, so it exists
on Linux (though not on BSD derived OS X). The test as written passed on
Linux, even with the TypeError it is supposed to be checking for deleted
from spawn(). It would also pass on Windows if a ls.exe existed.
The approach is unnecessarily obscure, assert.throw() is for asserting
code throws, using it is more clear and works regardless of what
commands do or do not exist.
PR-URL: https://github.com/joyent/node/pull/8454
Reviewed-by: Trevor Norris <trev.norris@gmail.com>
Cherry-picked-from:
|
||
---|---|---|
.. | ||
addons | ||
debugger | ||
disabled | ||
fixtures | ||
gc | ||
internet | ||
message | ||
parallel | ||
pummel | ||
sequential | ||
testpy | ||
timers | ||
common.js |