Skip to content

Commit

Permalink
test: remove require('buffer') from 4 test files
Browse files Browse the repository at this point in the history
Remove superfluous import from:

* test/parallel/test-buffer-fakes.js
* test/parallel/test-buffer-includes.js
* test/parallel/test-buffer-indexof.js
* test/parallel/test-buffer-new.js

Refs: #13836
PR-URL: #13846
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Alexey Orlenko <eaglexrlnk@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jackson Tian <shyvo1987@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
  • Loading branch information
leizongmin authored and addaleax committed Jun 24, 2017
1 parent 9b7c639 commit 0658a1f
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 6 deletions.
1 change: 0 additions & 1 deletion test/parallel/test-buffer-fakes.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

require('../common');
const assert = require('assert');
const Buffer = require('buffer').Buffer;

function FakeBuffer() { }
Object.setPrototypeOf(FakeBuffer, Buffer);
Expand Down
2 changes: 0 additions & 2 deletions test/parallel/test-buffer-includes.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
const common = require('../common');
const assert = require('assert');

const Buffer = require('buffer').Buffer;

const b = Buffer.from('abcdef');
const buf_a = Buffer.from('a');
const buf_bc = Buffer.from('bc');
Expand Down
2 changes: 0 additions & 2 deletions test/parallel/test-buffer-indexof.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
require('../common');
const assert = require('assert');

const Buffer = require('buffer').Buffer;

const b = Buffer.from('abcdef');
const buf_a = Buffer.from('a');
const buf_bc = Buffer.from('bc');
Expand Down
1 change: 0 additions & 1 deletion test/parallel/test-buffer-new.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,5 @@

require('../common');
const assert = require('assert');
const Buffer = require('buffer').Buffer;

assert.throws(() => new Buffer(42, 'utf8'), /first argument must be a string/);

0 comments on commit 0658a1f

Please sign in to comment.