diff --git a/src/compiler/pre-transform/codemods/import-declaration.test.ts b/src/compiler/pre-transform/codemods/import-declaration.test.ts
index 1a577641..ceaeade2 100644
--- a/src/compiler/pre-transform/codemods/import-declaration.test.ts
+++ b/src/compiler/pre-transform/codemods/import-declaration.test.ts
@@ -1,4 +1,3 @@
-import pkg from '@storybook/addon-svelte-csf/package.json' with { type: 'json' };
import type { ImportDeclaration } from 'estree';
import { print } from 'svelte-ast-print';
import { describe, it } from 'vitest';
@@ -11,39 +10,39 @@ describe(transformImportDeclaration.name, () => {
it("removes legacy components and add 'defineMeta'", async ({ expect }) => {
const code = `
`;
const node = await parseAndExtractSvelteNode(code, 'ImportDeclaration');
expect(print(transformImportDeclaration({ node }))).toMatchInlineSnapshot(
- `"import { defineMeta } from "${pkg.name}";"`
+ `"import { defineMeta } from "@storybook/addon-svelte-csf";"`
);
});
it("it doesn't remove existing 'defineMeta'", async ({ expect }) => {
const code = `
`;
const node = await parseAndExtractSvelteNode(code, 'ImportDeclaration');
expect(print(transformImportDeclaration({ node }))).toMatchInlineSnapshot(
- `"import { defineMeta } from "${pkg.name}";"`
+ `"import { defineMeta } from "@storybook/addon-svelte-csf";"`
);
});
it("it doesn't remove existing 'setTemplate'", async ({ expect }) => {
const code = `
`;
const node = await parseAndExtractSvelteNode(code, 'ImportDeclaration');
expect(print(transformImportDeclaration({ node }))).toMatchInlineSnapshot(
- `"import { defineMeta, setTemplate } from "${pkg.name}";"`
+ `"import { defineMeta, setTemplate } from "@storybook/addon-svelte-csf";"`
);
});
});