test: update packages/ test configs
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
/** @type {import('jest').Config} */
|
/** @type {import('jest').Config} */
|
||||||
const customJestConfig = {
|
const customJestConfig = {
|
||||||
extensionsToTreatAsEsm: ['.ts', '.tsx'],
|
extensionsToTreatAsEsm: ['.ts', '.tsx'],
|
||||||
setupFilesAfterEnv: ['./test/jest.setup.ts'],
|
setupFilesAfterEnv: ['<rootDir>/test/jest.setup.ts'],
|
||||||
moduleNameMapper: {
|
moduleNameMapper: {
|
||||||
'\\.(css|scss)$': '<rootDir>/test/helpers/mocks/emptyModule.js',
|
'\\.(css|scss)$': '<rootDir>/test/helpers/mocks/emptyModule.js',
|
||||||
'\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$':
|
'\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$':
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ import baseConfig from '../../jest.config.js'
|
|||||||
/** @type {import('@jest/types').Config} */
|
/** @type {import('@jest/types').Config} */
|
||||||
const customJestConfig = {
|
const customJestConfig = {
|
||||||
...baseConfig,
|
...baseConfig,
|
||||||
globalSetup: null,
|
setupFilesAfterEnv: null,
|
||||||
testMatch: ['**/src/**/?(*.)+(spec|test|it-test).[tj]s?(x)'],
|
testMatch: ['**/src/**/?(*.)+(spec|test|it-test).[tj]s?(x)'],
|
||||||
testTimeout: 20000,
|
testTimeout: 20000,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,9 +1,9 @@
|
|||||||
import baseConfig from '../../jest.config.js'
|
import baseConfig from '../../jest.config.js'
|
||||||
|
|
||||||
/** @type {import('@jest/types').Config} */
|
/** @type {import('jest').Config} */
|
||||||
const customJestConfig = {
|
const customJestConfig = {
|
||||||
...baseConfig,
|
...baseConfig,
|
||||||
globalSetup: null,
|
setupFilesAfterEnv: null,
|
||||||
testMatch: ['**/src/**/?(*.)+(spec|test|it-test).[tj]s?(x)'],
|
testMatch: ['**/src/**/?(*.)+(spec|test|it-test).[tj]s?(x)'],
|
||||||
testTimeout: 20000,
|
testTimeout: 20000,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,14 +1,11 @@
|
|||||||
module.exports = {
|
import baseConfig from '../../jest.config.js'
|
||||||
moduleNameMapper: {
|
|
||||||
'\\.(css|scss)$': '<rootDir>/src/webpack/mocks/emptyModule.js',
|
/** @type {import('jest').Config} */
|
||||||
'\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$':
|
const customJestConfig = {
|
||||||
'<rootDir>/src/webpack/mocks/fileMock.js',
|
...baseConfig,
|
||||||
},
|
setupFilesAfterEnv: null,
|
||||||
testEnvironment: 'node',
|
testMatch: ['**/src/**/?(*.)+(spec|test|it-test).[tj]s?(x)'],
|
||||||
testMatch: ['**/src/**/*.spec.ts'],
|
testTimeout: 20000,
|
||||||
testTimeout: 60000,
|
|
||||||
transform: {
|
|
||||||
'^.+\\.(ts|tsx)?$': 'ts-jest',
|
|
||||||
},
|
|
||||||
verbose: true,
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export default customJestConfig
|
||||||
|
|||||||
Reference in New Issue
Block a user