Skip to content

Commit

Permalink
build(common): update jest version & remove ts-jest (#629)
Browse files Browse the repository at this point in the history
  • Loading branch information
artyorsh authored Sep 20, 2019
1 parent b9658a4 commit 66f04ca
Show file tree
Hide file tree
Showing 5 changed files with 283 additions and 343 deletions.
28 changes: 10 additions & 18 deletions jest.config.js
Original file line number Diff line number Diff line change
@@ -1,26 +1,18 @@
const { defaults: tsJestConfig } = require('ts-jest/presets');
const { pathsToModuleNameMapper } = require('ts-jest/utils');
const tsConfig = require('./tsconfig');

module.exports = {
...tsJestConfig,
preset: 'react-native',
transform: {
...tsJestConfig.transform,
'\\.js$': '<rootDir>/node_modules/react-native/jest/preprocessor.js',
},
globals: {
'ts-jest': {
babelConfig: true,
tsConfig: './tsconfig.test.json',
},
},
cacheDirectory: './dist/jest/cache',
coverageDirectory: './dist/jest/coverage',
snapshotResolver: '<rootDir>/jest.config.snapshot',
moduleNameMapper: pathsToModuleNameMapper(tsConfig.compilerOptions.paths, {
prefix: '<rootDir>/',
}),
moduleNameMapper: {
"^@ui-kitten/*": "<rootDir>/src/$1",
"^@kitten/*": "<rootDir>/src/framework/$1",
"^react-native-ui-kitten": "<rootDir>/src/framework/$1",
},
moduleFileExtensions: [
'ts',
'tsx',
'js',
],
modulePathIgnorePatterns: [
'<rootDir>/src/playground/',
],
Expand Down
Loading

0 comments on commit 66f04ca

Please sign in to comment.