Skip to main content
Glama

mcp-adr-analysis-server

by tosin2013
jest.config.js3.24 kB
export default { preset: 'ts-jest/presets/default-esm', extensionsToTreatAsEsm: ['.ts'], moduleNameMapper: { '^(\\.{1,2}/.*)\\.js$': '$1', // Mock tree-sitter native modules that fail in Jest VM environment '^tree-sitter$': '<rootDir>/tests/__mocks__/tree-sitter.ts', '^tree-sitter-typescript$': '<rootDir>/tests/__mocks__/tree-sitter-typescript.ts', '^tree-sitter-javascript$': '<rootDir>/tests/__mocks__/tree-sitter-javascript.ts', '^tree-sitter-python$': '<rootDir>/tests/__mocks__/tree-sitter-python.ts', '^tree-sitter-yaml$': '<rootDir>/tests/__mocks__/tree-sitter-yaml.ts', '^tree-sitter-json$': '<rootDir>/tests/__mocks__/tree-sitter-json.ts', '^tree-sitter-bash$': '<rootDir>/tests/__mocks__/tree-sitter-bash.ts', '^tree-sitter-dockerfile$': '<rootDir>/tests/__mocks__/tree-sitter-dockerfile.ts', '^@tree-sitter-grammars/tree-sitter-hcl$': '<rootDir>/tests/__mocks__/@tree-sitter-grammars/tree-sitter-hcl.ts', }, testEnvironment: 'node', roots: ['<rootDir>/src', '<rootDir>/tests'], testMatch: ['**/__tests__/**/*.ts', '**/?(*.)+(spec|test).ts'], transform: { '^.+\\.ts$': [ 'ts-jest', { useESM: true, tsconfig: { module: 'ESNext', target: 'ES2022', moduleResolution: 'node', }, }, ], }, // Jest 30.x compatibility: disable worker threads to allow dynamic imports workerThreads: false, collectCoverageFrom: [ 'src/**/*.ts', '!src/**/*.d.ts', '!src/**/__tests__/**', '!src/**/*.test.ts', ], coverageDirectory: 'coverage', coverageReporters: ['text', 'lcov', 'html'], coverageThreshold: { global: { branches: 85, functions: 85, lines: 85, statements: 85, }, }, // Skip performance tests and problematic integration tests to focus on feature coverage testPathIgnorePatterns: [ '/node_modules/', '.*\\.performance\\.test\\.ts$', 'tests/performance/', 'tests/performance-effectiveness.test.ts', 'tests/integration/memory-migration-integration.test.ts', 'tests/tools/deployment-readiness-tool.test.ts', ], setupFilesAfterEnv: ['<rootDir>/tests/setup.ts'], // Dynamic timeout based on test type - will be overridden by test infrastructure testTimeout: 15000, verbose: true, clearMocks: true, restoreMocks: true, // Enhanced error handling errorOnDeprecated: true, // Memory management logHeapUsage: true, // Improved test isolation resetMocks: true, resetModules: false, // Keep modules cached for performance // Concurrent test limits for resource management maxWorkers: process.env.CI ? 2 : '50%', // Test result processing testResultsProcessor: undefined, // Global setup/teardown for infrastructure globalSetup: undefined, globalTeardown: undefined, // Enhanced reporting reporters: [ 'default', ...(process.env.CI ? [['jest-junit', { outputDirectory: 'test-results', outputName: 'junit.xml' }]] : []), ], // Test environment options testEnvironmentOptions: { // Node.js specific options node: { // Increase memory limit for large tests max_old_space_size: process.env.CI ? 2048 : 4096, }, }, };

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/tosin2013/mcp-adr-analysis-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server