mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Add stat to fake FS
Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
parent
69cfe9a25e
commit
36063d86af
@ -20,6 +20,7 @@ const fsInjectable = getInjectable({
|
||||
lstat,
|
||||
rm,
|
||||
access,
|
||||
stat,
|
||||
},
|
||||
ensureDir,
|
||||
ensureDirSync,
|
||||
@ -54,6 +55,7 @@ const fsInjectable = getInjectable({
|
||||
ensureDir: ensureDir as (path: string, options?: number | fse.EnsureOptions ) => Promise<void>,
|
||||
ensureDirSync,
|
||||
createReadStream,
|
||||
stat,
|
||||
};
|
||||
},
|
||||
causesSideEffects: true,
|
||||
|
||||
@ -61,6 +61,7 @@ export const getOverrideFsWithFakes = () => {
|
||||
ensureDir: async (path, opts) => ensureDirSync(path, opts),
|
||||
ensureDirSync,
|
||||
createReadStream: root.createReadStream as any,
|
||||
stat: root.promises.stat as any,
|
||||
}));
|
||||
};
|
||||
};
|
||||
|
||||
Loading…
Reference in New Issue
Block a user