Skip to content

Commit

Permalink
fix: update to pass diagnostics root and use correct import
Browse files Browse the repository at this point in the history
  • Loading branch information
DJankauskas committed Jul 14, 2023
1 parent 0a323f6 commit 7f43ac1
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions packages/ts-to-zod/src/__tests__/multiFileTestCase.ts
@@ -1,7 +1,8 @@
import * as tm from "ts-morph";
import { SchemaGenContext, convertSymbol } from "../convertType";
import { testProject } from "./testProject";
import { GenOptions, generateFiles } from "../generateFiles";
import { generateFiles } from "../generateFiles";
import { GenOptions } from "../filePathConfig";
import * as path from "path";
import pkgUp from "pkg-up";

Expand Down Expand Up @@ -30,9 +31,9 @@ export const multiFileTestCase = async (options: {
throw new Error(`failed to get Symbol from SourceFile`);
}
const ctx = new SchemaGenContext(testProject);
convertSymbol(ctx, symbol);
convertSymbol(ctx, symbol, { variant: "node", node });
const rootPackageJson = await pkgUp({
cwd: __dirname
cwd: __dirname,
});
if (!rootPackageJson) {
throw new Error("test must run within npm package");
Expand Down

0 comments on commit 7f43ac1

Please sign in to comment.