Browse Source

test: throw check in test-zlib-write-after-close

PR-URL: https://github.com/nodejs/node/pull/11482
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com>
v4.x
Jason Wilson 8 years ago
committed by Myles Borins
parent
commit
f0eee61a93
No known key found for this signature in database GPG Key ID: 933B01F40B5CA946
  1. 4
      test/parallel/test-zlib-write-after-close.js

4
test/parallel/test-zlib-write-after-close.js

@ -6,7 +6,5 @@ var zlib = require('zlib');
zlib.gzip('hello', common.mustCall(function(err, out) {
var unzip = zlib.createGunzip();
unzip.close(common.mustCall(function() {}));
assert.throws(function() {
unzip.write(out);
});
assert.throws(() => unzip.write(out), /^Error: zlib binding closed$/);
}));

Loading…
Cancel
Save