diff --git a/tests/Expressions/__snapshots__/wrapper_same_line.snap.twig b/tests/Expressions/__snapshots__/wrapper_same_line.snap.twig new file mode 100644 index 0000000..ab1ee69 --- /dev/null +++ b/tests/Expressions/__snapshots__/wrapper_same_line.snap.twig @@ -0,0 +1,3 @@ +{{ svg('path/to/file.svg')|attr({ + class: 'w-6 h-6' +}) }} diff --git a/tests/Expressions/jsfmt.spec.js b/tests/Expressions/jsfmt.spec.js index 8a67e67..06b464b 100644 --- a/tests/Expressions/jsfmt.spec.js +++ b/tests/Expressions/jsfmt.spec.js @@ -91,4 +91,11 @@ describe("Expressions", () => { }); await expect(actual).toMatchFileSnapshot(snapshotFile); }); + + it("Print expression wrapper on same line", async () => { + const { actual, snapshotFile } = await run_spec(import.meta.url, { + source: "wrapper_same_line.twig" + }); + await expect(actual).toMatchFileSnapshot(snapshotFile); + }); }); diff --git a/tests/Expressions/wrapper_same_line.twig b/tests/Expressions/wrapper_same_line.twig new file mode 100644 index 0000000..7f66217 --- /dev/null +++ b/tests/Expressions/wrapper_same_line.twig @@ -0,0 +1,5 @@ +{{ +svg("path/to/file.svg")|attr({ + class: "w-6 h-6", +}) +}}