mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-16 09:36:44 +00:00
feat(core): Add OIDC support for SSO (#15988)
Co-authored-by: Andreas Fitzek <andreas.fitzek@n8n.io>
This commit is contained in:
@@ -13,6 +13,17 @@ const tsJestOptions = {
|
||||
|
||||
const isCoverageEnabled = process.env.COVERAGE_ENABLED === 'true';
|
||||
|
||||
const esmDependencies = [
|
||||
'pdfjs-dist',
|
||||
'openid-client',
|
||||
'oauth4webapi',
|
||||
'jose',
|
||||
// Add other ESM dependencies that need to be transformed here
|
||||
];
|
||||
|
||||
const esmDependenciesPattern = esmDependencies.join('|');
|
||||
const esmDependenciesRegex = `node_modules/(${esmDependenciesPattern})/.+\\.m?js$`;
|
||||
|
||||
/** @type {import('jest').Config} */
|
||||
const config = {
|
||||
verbose: true,
|
||||
@@ -21,7 +32,7 @@ const config = {
|
||||
testPathIgnorePatterns: ['/dist/', '/node_modules/'],
|
||||
transform: {
|
||||
'^.+\\.ts$': ['ts-jest', tsJestOptions],
|
||||
'node_modules/pdfjs-dist/.+\\.mjs$': [
|
||||
[esmDependenciesRegex]: [
|
||||
'babel-jest',
|
||||
{
|
||||
presets: ['@babel/preset-env'],
|
||||
@@ -29,7 +40,7 @@ const config = {
|
||||
},
|
||||
],
|
||||
},
|
||||
transformIgnorePatterns: ['/dist/', '/node_modules/(?!.*pdfjs-dist/)'],
|
||||
transformIgnorePatterns: [`/node_modules/(?!${esmDependenciesPattern})/`],
|
||||
// This resolve the path mappings from the tsconfig relative to each jest.config.js
|
||||
moduleNameMapper: compilerOptions?.paths
|
||||
? pathsToModuleNameMapper(compilerOptions.paths, {
|
||||
|
||||
Reference in New Issue
Block a user