@shelf/jest-mongodb does not work with TypeScript
See original GitHub issueHere the config I am using for jest in jest.config.js
:
module.exports = {
transform: {
'^.+\\.jsx?$': 'babel-jest',
'^.+\\.ts?$': 'ts-jest'
},
rootDir: './lib',
roots: ['<rootDir>'],
moduleFileExtensions: ['ts', 'js', 'json', 'node'],
preset: "@shelf/jest-mongodb"
};
Jest fails to run tests just saying “Determining test suites to run…”
Works if I replace preset: "@shelf/jest-mongodb"
with preset: "ts-jest"
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:6
Top Results From Across the Web
How to configure jest-mongodb(@shelf/jest ... - Stack Overflow
Hey I have referred documentation and implemented in javascript code. It works fine and test cases are passing. but when trying with typescript...
Read more >@shelf/jest-mongodb - npm
Run your tests using Jest & MongoDB in Memory server. Latest version: 4.1.4, last published: a month ago. Start using @shelf/jest-mongodb in ...
Read more >How to configure jest-mongodb(@shelf ... - appsloveworld.com
Jest MongoDB provides all required configuration to run your tests using MongoDB. Described Here. First you need to install @shelf/jest-mongodb,
Read more >Using with MongoDB - Jest
Jest MongoDB provides all required configuration to run your tests using MongoDB. First install @shelf/jest-mongodb. npm; Yarn. npm ...
Read more >How to test MongoDB related functionality with Jest ... - YouTube
In this episode I show you a simple way to test MongoDB related functionality with Jest in Node.js using TypeScript.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
We use it with a Typescript setup, our
jest.config.js
looks like this:// EDIT: But as you see, we’re not using
babel
, so you might need to configurets-jest
differently, in order to pick up yourbabel
preset: Maybe this helps - https://kulshekhar.github.io/ts-jest/user/config/babelConfig@francesco-albanese You left this issue open. Sounds like you should be able to close it.