From b7c7ccd8a5379954585f4c555472e16e5eb7c3be Mon Sep 17 00:00:00 2001 From: Victor Giers Date: Tue, 12 May 2026 22:49:39 +0200 Subject: [PATCH] Add integration tests for path curve mode and sampled resolution features --- tests/unit/path-inspector.integration.test.tsx | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/tests/unit/path-inspector.integration.test.tsx b/tests/unit/path-inspector.integration.test.tsx index 119ac278..a8c1e891 100644 --- a/tests/unit/path-inspector.integration.test.tsx +++ b/tests/unit/path-inspector.integration.test.tsx @@ -132,6 +132,8 @@ describe("Path inspector", () => { expect(screen.getByTestId("path-name")).toHaveValue(""); expect(screen.getByTestId("path-loop")).not.toBeChecked(); + expect(screen.getByTestId("path-curve-mode")).toHaveValue("linear"); + expect(screen.getByTestId("path-sampled-resolution")).toHaveValue(12); expect(screen.getByTestId("path-point-0-x")).toHaveValue(-1); expect(screen.getByTestId("path-point-1-x")).toHaveValue(1); @@ -142,6 +144,16 @@ describe("Path inspector", () => { }); fireEvent.blur(screen.getByTestId("path-name")); fireEvent.click(screen.getByTestId("path-loop")); + fireEvent.change(screen.getByTestId("path-curve-mode"), { + target: { + value: "catmullRom" + } + }); + fireEvent.change(screen.getByTestId("path-sampled-resolution"), { + target: { + value: "16" + } + }); fireEvent.change(screen.getByTestId("path-point-1-z"), { target: { value: "2" @@ -155,7 +167,9 @@ describe("Path inspector", () => { expect(updatedPath).toMatchObject({ name: "Patrol Route", - loop: true + loop: true, + curveMode: "catmullRom", + sampledResolution: 16 }); expect(updatedPath?.points).toHaveLength(3); expect(updatedPath?.points[1]?.position).toEqual({