mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 01:56:46 +00:00
chore: Enfore consistent file-name casing on all backend packages (#15755)
This commit is contained in:
committed by
GitHub
parent
66d339c0d8
commit
3a2a70f193
19
packages/workflow/test/helpers.ts
Normal file
19
packages/workflow/test/helpers.ts
Normal file
@@ -0,0 +1,19 @@
|
||||
import { readFileSync } from 'fs';
|
||||
import path from 'path';
|
||||
|
||||
import type { INodeTypes } from '@/interfaces';
|
||||
|
||||
import { NodeTypes as NodeTypesClass } from './node-types';
|
||||
|
||||
let nodeTypesInstance: NodeTypesClass | undefined;
|
||||
|
||||
export function NodeTypes(): INodeTypes {
|
||||
if (nodeTypesInstance === undefined) {
|
||||
nodeTypesInstance = new NodeTypesClass();
|
||||
}
|
||||
return nodeTypesInstance;
|
||||
}
|
||||
|
||||
const BASE_DIR = path.resolve(__dirname, '..');
|
||||
export const readJsonFileSync = <T>(filePath: string) =>
|
||||
JSON.parse(readFileSync(path.join(BASE_DIR, filePath), 'utf-8')) as T;
|
||||
Reference in New Issue
Block a user