1 Star 0 Fork 300

royalice/L7

forked from antv/L7 
加入 Gitee
與超過 1200 萬 開發者一起發現、參與優秀開源項目,私有倉庫也完全免費 :)
免費加入
文件
克隆/下載
jest.config.ts 1.30 KB
一鍵複製 編輯 原始數據 按行查看 歷史
import type { Config } from 'jest';
const sharedConfig = {
transform: {
// use typescript to convert from esm to cjs
'[.](m|c)?(ts|js)(x)?$': ['ts-jest', {
'isolatedModules': true,
'tsconfig': 'tsconfig.json'
},
],
"^.+.(glsl)$":"jest-text-transformer"
// '\\.[jt]sx?$': 'esbuild-jest',
},
// any tests that operate on dist files shouldn't compile them again.
transformIgnorePatterns: ['<rootDir>/dist','^.+\\.js$'],
modulePathIgnorePatterns: ['<rootDir>/dist'],
moduleNameMapper: {
'@antv/l7-(.+)$': '<rootDir>packages/$1/src',
"^.+.(css)$": "jest-text-transformer"
},
} as Partial<Config>;
const config: Config = {
testEnvironment: 'jsdom',
setupFiles: [
'jest-canvas-mock',
],
setupFilesAfterEnv: [ '<rootDir>jest/setupTests.ts' ],
testMatch: [
'**/__tests__/*.spec.+(ts|tsx|js)',
'**/*.test.+(ts|tsx|js)',
'**/__tests__/*/*.spec.+(ts|tsx|js)',
],
coverageReporters: ['html', 'lcov', 'clover'],
coveragePathIgnorePatterns: ['/node_modules/', '/iconfont/'],
coverageThreshold: {
global: {
branches: 9,
functions: 11.5,
lines: 15,
statements: 15,
},
},
...sharedConfig
};
export default config;
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
TypeScript
1
https://gitee.com/royalline/L7.git
git@gitee.com:royalline/L7.git
royalline
L7
L7
master

搜索幫助

0d507c66 1850385 C8b1a773 1850385