I am testing fileA.js, which requires fileB.js
In fileA.test.js, I wish to mock all methods from fileB.js except one.
In fileA.test.js I have:
const common = require("../src/fileB");
jest.mock("../src/fileB");
There is one method I do not wish to be mocked. Is this sort of thing possible in nodeJS?
Thank you.