diff --git a/src/compiler/pre-transform/codemods/legacy-story.test.ts b/src/compiler/pre-transform/codemods/legacy-story.test.ts
index a41e934..bd3120f 100644
--- a/src/compiler/pre-transform/codemods/legacy-story.test.ts
+++ b/src/compiler/pre-transform/codemods/legacy-story.test.ts
@@ -192,4 +192,29 @@ describe(transformLegacyStory.name, () => {
"
`);
});
+
+ it("when both directives 'let:args' and 'let:context' is used then it wraps Story fragment with 'children' snippet block", async ({
+ expect,
+ }) => {
+ const code = `
+
+
+
+ {args.title}
+ {context.id}
+
+ `;
+ const node = await parseAndExtractSvelteNode(code, 'Component');
+
+ expect(print(transformLegacyStory({ node }))).toMatchInlineSnapshot(`
+ "
+ {#snippet children(args, context)}
+ {args.title}
+ {context.id}
+ {/snippet}
+ "
+ `);
+ });
});