diff options
Diffstat (limited to 'test/parallel/test-zlib-dictionary-fail.js')
-rw-r--r-- | test/parallel/test-zlib-dictionary-fail.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/parallel/test-zlib-dictionary-fail.js b/test/parallel/test-zlib-dictionary-fail.js index b4a344ceef..2c8939c68f 100644 --- a/test/parallel/test-zlib-dictionary-fail.js +++ b/test/parallel/test-zlib-dictionary-fail.js @@ -12,17 +12,17 @@ var zlib = require('zlib'); })); // String "test" encoded with dictionary "dict". - stream.write(Buffer([0x78, 0xBB, 0x04, 0x09, 0x01, 0xA5])); + stream.write(Buffer.from([0x78, 0xBB, 0x04, 0x09, 0x01, 0xA5])); })(); // Should raise an error, not trigger an assertion in src/node_zlib.cc (function() { - var stream = zlib.createInflate({ dictionary: Buffer('fail') }); + var stream = zlib.createInflate({ dictionary: Buffer.from('fail') }); stream.on('error', common.mustCall(function(err) { assert(/Bad dictionary/.test(err.message)); })); // String "test" encoded with dictionary "dict". - stream.write(Buffer([0x78, 0xBB, 0x04, 0x09, 0x01, 0xA5])); + stream.write(Buffer.from([0x78, 0xBB, 0x04, 0x09, 0x01, 0xA5])); })(); |