Not exactly sure what's going on with your mocking setup, but I'd recommend checking out https://www.npmjs.com/package/nock or https://mswjs.io/
These tools mock at the http level, leaving everything else intact. I've had really amazing test suites set up in the past using them.