diff --git a/src/common/fs/fs.injectable.ts b/src/common/fs/fs.injectable.ts index 1c4a8fc0b3..70c0ff89fb 100644 --- a/src/common/fs/fs.injectable.ts +++ b/src/common/fs/fs.injectable.ts @@ -32,6 +32,7 @@ const fsInjectable = getInjectable({ pathExistsSync, pathExists, copy, + createReadStream, } = fse; return { @@ -52,6 +53,7 @@ const fsInjectable = getInjectable({ copy: copy as (src: string, dest: string, options?: fse.CopyOptions) => Promise, ensureDir: ensureDir as (path: string, options?: number | fse.EnsureOptions ) => Promise, ensureDirSync, + createReadStream, }; }, causesSideEffects: true, diff --git a/src/test-utils/override-fs-with-fakes.ts b/src/test-utils/override-fs-with-fakes.ts index eea08c7943..6cbb41523a 100644 --- a/src/test-utils/override-fs-with-fakes.ts +++ b/src/test-utils/override-fs-with-fakes.ts @@ -60,6 +60,7 @@ export const getOverrideFsWithFakes = () => { copy: async (src, dest) => { throw new Error(`Tried to copy '${src}' to '${dest}'. Copying is not yet supported`); }, ensureDir: async (path, opts) => ensureDirSync(path, opts), ensureDirSync, + createReadStream: root.createReadStream as any, })); }; };