Skip to content

Commit 73a01be

Browse files
Jean Lauliacfacebook-github-bot
authored andcommitted
packager-worker-for-buck: transformCommand: add test
Reviewed By: davidaurelio Differential Revision: D6232002 fbshipit-source-id: 8bdd0dd0dabff4b92b4c2d7b4c3f7a2d90723bee
1 parent e0202e4 commit 73a01be

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

local-cli/__mocks__/fs.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ fs.open.mockImplementation(function(filepath) {
255255
}
256256

257257
if (error || data == null) {
258-
error = Error(`ENOENT: no such file or directory, open ${filepath}`);
258+
error = Error(`ENOENT: no such file or directory: \`${filepath}\``);
259259
}
260260
if (data != null) {
261261
/* global Buffer: true */
@@ -409,7 +409,9 @@ function getToNode(filepath) {
409409
}
410410
node = node[part];
411411
if (node == null) {
412-
const err = new Error('ENOENT: no such file or directory');
412+
const err = new Error(
413+
`ENOENT: no such file or directory: \`${filepath}\``,
414+
);
413415
err.code = 'ENOENT';
414416
throw err;
415417
}

0 commit comments

Comments
 (0)