-
Notifications
You must be signed in to change notification settings - Fork 276
Open
Description
Although this is for tracing bugs, since my question is specific to csv-parser
I thought maybe it's the right place to ask. (hope you don't mind)
I have the following code to parse csv files:
const records = [];
const parser = fs
.createReadStream(`${process.cwd()}/${file.destination}/${file.filename}`)
.pipe(parse({}));
for await (const record of parser) {
records.push(record);
}
I wanted to know how to mock this code in unit tests with jest. Any idea would be appreciated.
Metadata
Metadata
Assignees
Labels
No labels