Skip to content

Commit

Permalink
fixup! test: add comment
Browse files Browse the repository at this point in the history
  • Loading branch information
RaisinTen committed Oct 22, 2022
1 parent 074c8dd commit 9ec74c9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/parallel/test-vfs.js
Expand Up @@ -39,7 +39,6 @@ common.expectWarning(
process.on('warning', common.mustCall());

const originalStat = Module._stat;
// TODO(aduh95): We'd like to have a better way to achieve this without monkey-patching.
Module._stat = function(filename) {
if (!filename.startsWith(process.execPath)) {
return originalStat(filename);
Expand All @@ -60,6 +59,7 @@ Module._stat = function(filename) {
};

const originalReadFileSync = fs.readFileSync;
// TODO(aduh95): We'd like to have a better way to achieve this without monkey-patching fs.
fs.readFileSync = function readFileSync(pathArgument, options) {
if (!pathArgument.startsWith(process.execPath)) {
return originalReadFileSync.apply(this, arguments);
Expand Down

0 comments on commit 9ec74c9

Please sign in to comment.