Skip to content

Commit

Permalink
proxy.spec.js: use Buffer.from()
Browse files Browse the repository at this point in the history
Buffer() is deprecated according to
the warnings when running tests.
  • Loading branch information
pjonsson committed May 1, 2024
1 parent 03c15ca commit 7e4b79d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion spec/proxy.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ describe('proxy', function() {
.send('boaty mcboatface')
.expect(200)
.expect(function() {
expect(fakeRequest.calls.argsFor(0)[0].body).toEqual(new Buffer('boaty mcboatface'));
expect(fakeRequest.calls.argsFor(0)[0].body).toEqual(Buffer.from('boaty mcboatface'));
})
.end(assert(done));
});
Expand Down

0 comments on commit 7e4b79d

Please sign in to comment.