mirror of
https://github.com/farcasclaudiu/Flowise.git
synced 2026-06-22 09:01:09 +03:00
b126472816
* feat: add JSONPathExtractor tool with lodash-based path extraction - Implement JSONPathExtractor tool for extracting values from JSON using path notation - Use lodash.get for robust path extraction supporting edge cases (numeric string keys, array indexing) - Add configurable error handling with returnNullOnError parameter - Include comprehensive test suite with 34 tests covering all scenarios - Support JSON strings, objects, and arrays as input * fix lint * Update pnpm-lock.yaml * fix: exclude test files from TypeScript compilation Prevents test files from being included in the dist folder which was causing "jest is not defined" errors during server startup. --------- Co-authored-by: Henry Heng <henryheng@flowiseai.com>
16 lines
450 B
JavaScript
16 lines
450 B
JavaScript
module.exports = {
|
|
preset: 'ts-jest',
|
|
testEnvironment: 'node',
|
|
roots: ['<rootDir>/nodes'],
|
|
transform: {
|
|
'^.+\\.tsx?$': 'ts-jest'
|
|
},
|
|
testRegex: '(/__tests__/.*|(\\.|/)(test|spec))\\.tsx?$',
|
|
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json', 'node'],
|
|
verbose: true,
|
|
testPathIgnorePatterns: ['/node_modules/', '/dist/'],
|
|
moduleNameMapper: {
|
|
'^../../../src/(.*)$': '<rootDir>/src/$1'
|
|
}
|
|
}
|