rollup-jest
rollup-jest copied to clipboard
Doesn't hoist `jest.mock` and similar
All jest docs implicitly rely on the fact that the default configuration hoists jest.mock
when mocking modules. rollup-jest
does not do this.
I think there either needs to be a big warning in the README or, better yet, a plugin to hoist those calls.
References: https://github.com/facebook/jest/issues/2582#issuecomment-378677440, https://github.com/facebook/jest/blob/main/packages/babel-plugin-jest-hoist/README.md, https://github.com/kulshekhar/ts-jest/blob/main/src/transformers/hoist-jest.ts