Skip to content

Commit

Permalink
test: remove fixturesDir from common module
Browse files Browse the repository at this point in the history
Remove common.fixturesDir. All tests now use the the common/fixtures
module instead.

PR-URL: nodejs#17400
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Lance Ball <lball@redhat.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
  • Loading branch information
Trott committed Dec 4, 2017
1 parent f9660b7 commit f299922
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 8 deletions.
5 changes: 0 additions & 5 deletions test/common/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,11 +127,6 @@ Returns a new promise that will propagate `promise` resolution or rejection if
that happens within the `timeoutMs` timespan, or rejects with `error` as
a reason otherwise.

### fixturesDir
* [&lt;String>]

Path to the 'fixtures' directory.

### getArrayBufferViews(buf)
* `buf` [&lt;Buffer>]
* return [&lt;ArrayBufferView&#91;&#93;>]
Expand Down
4 changes: 1 addition & 3 deletions test/common/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@ const testRoot = process.env.NODE_TEST_DIR ?

const noop = () => {};

exports.fixturesDir = fixturesDir;

// Using a `.` prefixed name, which is the convention for "hidden" on POSIX,
// gets tools to ignore it by default or by simple rules, especially eslint.
let tmpDirName = '.tmp';
Expand Down Expand Up @@ -303,7 +301,7 @@ exports.childShouldThrowAndAbort = function() {

exports.ddCommand = function(filename, kilobytes) {
if (exports.isWindows) {
const p = path.resolve(exports.fixturesDir, 'create-file.js');
const p = path.resolve(fixturesDir, 'create-file.js');
return `"${process.argv[0]}" "${p}" "${filename}" ${kilobytes * 1024}`;
} else {
return `dd if=/dev/zero of="${filename}" bs=1024 count=${kilobytes}`;
Expand Down

0 comments on commit f299922

Please sign in to comment.