Uh oh!
There was an error while loading. Please reload this page.
test: check for error on invalid signal - #10026
Conversation
bnoordhuis
left a comment
There was a problem hiding this comment.
LGTM. CI: https://ci.nodejs.org/job/node-test-pull-request/5072/ (currently queued)
There was a problem hiding this comment.
Could you put a space before this comment, e.g. // Test...? :D
Asserts that an error should be thrown when an invalid signal is passed to process.kill
a82c7e2 to
5fdea9dCompare| // Test that kill throws an error for invalid signal | ||
| assert.throws(function() { process.kill(1, 'test'); }, Error); |
There was a problem hiding this comment.
This is ok but passing a regexp as the second argument would be better.
assert.throws(()=>{process.kill(1,'test');},/^Error:Unknownsignal:test$/);
Fishrock123
left a comment
There was a problem hiding this comment.
LGTM with @jasnell's suggestion.
Trott
commented
Dec 8, 2016
Asserts that an error should be thrown when an invalid signal is passed to process.kill(). PR-URL: nodejs#10026 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Trott
commented
Dec 9, 2016
Landed in 6aacef7. I agree with the nit about using a RegExp rather than a constructor for |
Asserts that an error should be thrown when an invalid signal is passed to process.kill(). PR-URL: #10026 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Asserts that an error should be thrown when an invalid signal is passed to process.kill(). PR-URL: #10026 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Asserts that an error should be thrown when an invalid signal is passed to process.kill(). PR-URL: #10026 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Asserts that an error should be thrown when an invalid signal is passed to process.kill(). PR-URL: #10026 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Asserts that an error should be thrown when an invalid signal is passed to process.kill(). PR-URL: #10026 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Asserts that an error should be thrown when an invalid signal is passed to process.kill(). PR-URL: #10026 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Asserts that an error should be thrown when an invalid signal is passed to process.kill(). PR-URL: #10026 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Checklist
make -j8 test(UNIX), orvcbuild test nosign(Windows) passesAffected core subsystem(s)
test
Description of change
Asserts that an error should be thrown when an invalid signal is passed to process.kill