Skip to content

Commit

Permalink
test: The Buffer() and new Buffer() constructors are deprecated (#1305)
Browse files Browse the repository at this point in the history
  • Loading branch information
flaambe authored and keithamus committed Jan 22, 2020
1 parent 7ff1273 commit 0e543bf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/expect.js
Expand Up @@ -1400,10 +1400,10 @@ describe('expect', function () {

if ('undefined' !== typeof Buffer) {
it('Buffer eql()', function () {
expect(new Buffer([ 1 ])).to.eql(new Buffer([ 1 ]));
expect(Buffer.from([ 1 ])).to.eql(Buffer.from([ 1 ]));

err(function () {
expect(new Buffer([ 0 ])).to.eql(new Buffer([ 1 ]));
expect(Buffer.from([ 0 ])).to.eql(Buffer.from([ 1 ]));
}, 'expected <Buffer 00> to deeply equal <Buffer 01>');
});
}
Expand Down

0 comments on commit 0e543bf

Please sign in to comment.