Quick proof of concept for twenty-apps + twenty-cli, with local development / hot reload Let's discuss it! https://github.com/user-attachments/assets/c6789936-cd5f-4110-a265-863a6ac1af2d
41 lines
904 B
JavaScript
41 lines
904 B
JavaScript
const jestConfig = {
|
|
displayName: 'twenty-cli',
|
|
preset: '../../jest.preset.js',
|
|
testEnvironment: 'node',
|
|
transformIgnorePatterns: ['../../node_modules/'],
|
|
transform: {
|
|
'^.+\\.[tj]sx?$': [
|
|
'@swc/jest',
|
|
{
|
|
jsc: {
|
|
parser: { syntax: 'typescript', tsx: false },
|
|
},
|
|
},
|
|
],
|
|
},
|
|
moduleNameMapper: {
|
|
'^@/(.*)$': '<rootDir>/src/$1',
|
|
},
|
|
moduleFileExtensions: ['ts', 'js'],
|
|
extensionsToTreatAsEsm: ['.ts'],
|
|
coverageDirectory: './coverage',
|
|
testMatch: [
|
|
'<rootDir>/src/**/__tests__/**/*.(test|spec).{js,ts}',
|
|
'<rootDir>/src/**/?(*.)(test|spec).{js,ts}',
|
|
],
|
|
collectCoverageFrom: [
|
|
'src/**/*.{ts,js}',
|
|
'!src/**/*.d.ts',
|
|
'!src/cli.ts', // Exclude CLI entry point from coverage
|
|
],
|
|
coverageThreshold: {
|
|
global: {
|
|
statements: 2,
|
|
lines: 1,
|
|
functions: 5,
|
|
},
|
|
},
|
|
};
|
|
|
|
export default jestConfig;
|