We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f265789 commit cd016b2Copy full SHA for cd016b2
2 files changed
jest.config.mjs
@@ -3,6 +3,11 @@ export default {
3
preset: "ts-jest",
4
testEnvironment: "node",
5
moduleNameMapper: {
6
- "(.+)\.js$": "$1",
+ // Only map .js files in our src directory, not node_modules
7
+ "^src/(.+)\\.js$": "<rootDir>/src/$1",
8
},
9
+ // Add transformIgnorePatterns to handle ESM modules in node_modules
10
+ transformIgnorePatterns: [
11
+ "node_modules/(?!(@traceloop|js-tiktoken|base64-js)/)",
12
+ ],
13
};
tests/custom/integration/decorators.test.ts
@@ -1,7 +1,7 @@
1
import OpenAI from "openai";
2
-import { PromptRequest } from "../../src/api";
-import { HumanloopRuntimeError } from "../../src/error";
+import { PromptRequest } from "../../../src/api";
+import { HumanloopRuntimeError } from "../../../src/error";
import {
CleanupResources,
TestPrompt,
0 commit comments