Skip to content

Commit

Permalink
Add comment to updated test
Browse files Browse the repository at this point in the history
  • Loading branch information
nzakas committed Nov 19, 2018
1 parent 2d9f8be commit 2fea543
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tests/lib/util/npm-utils.js
Expand Up @@ -162,6 +162,13 @@ describe("npmUtils", () => {
});

it("should return false if package.json does not exist", () => {
/*
* Checking local file system directly, which does not
* contains package.json. This is necessary because mock-fs
* doesn't work in Node.js 11: it throws an error when
* a file is missing rather than returning false.
* TODO: Find a replacement for mock-fs that works in Node 11.
*/
assert.strictEqual(npmUtils.checkPackageJson("/"), false);
});
});
Expand Down

0 comments on commit 2fea543

Please sign in to comment.