diff options
author | cjihrig <cjihrig@gmail.com> | 2016-07-14 11:26:35 -0400 |
---|---|---|
committer | cjihrig <cjihrig@gmail.com> | 2016-07-15 15:50:01 -0400 |
commit | 6510eb5ddc802dcd25713c2b3cbb82711c94d075 (patch) | |
tree | 9f22bb1adff8ef2474267297873f03f1c3704d49 /test/parallel/test-http-server-reject-chunked-with-content-length.js | |
parent | 28d9485c25a0ddeb8817525e25d4c7bb1ee5013b (diff) | |
download | android-node-v8-6510eb5ddc802dcd25713c2b3cbb82711c94d075.tar.gz android-node-v8-6510eb5ddc802dcd25713c2b3cbb82711c94d075.tar.bz2 android-node-v8-6510eb5ddc802dcd25713c2b3cbb82711c94d075.zip |
test: s/assert.fail/common.fail as appropriate
Many tests use assert.fail(null, null, msg) where it would be
simpler to use common.fail(msg). This is largely because
common.fail() is fairly new. This commit makes the replacement
when applicable.
PR-URL: https://github.com/nodejs/node/pull/7735
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Diffstat (limited to 'test/parallel/test-http-server-reject-chunked-with-content-length.js')
-rw-r--r-- | test/parallel/test-http-server-reject-chunked-with-content-length.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/parallel/test-http-server-reject-chunked-with-content-length.js b/test/parallel/test-http-server-reject-chunked-with-content-length.js index b3284c3685..d8697cd38c 100644 --- a/test/parallel/test-http-server-reject-chunked-with-content-length.js +++ b/test/parallel/test-http-server-reject-chunked-with-content-length.js @@ -10,7 +10,7 @@ const reqstr = 'POST / HTTP/1.1\r\n' + 'Transfer-Encoding: chunked\r\n\r\n'; const server = http.createServer((req, res) => { - assert.fail(null, null, 'callback should not be invoked'); + common.fail('callback should not be invoked'); }); server.on('clientError', common.mustCall((err) => { assert(/^Parse Error/.test(err.message)); @@ -25,7 +25,7 @@ server.listen(0, () => { client.on('data', (data) => { // Should not get to this point because the server should simply // close the connection without returning any data. - assert.fail(null, null, 'no data should be returned by the server'); + common.fail('no data should be returned by the server'); }); client.on('end', common.mustCall(() => {})); }); |