Skip to content

Commit 7753b27

Browse files
committed
Update test to fail more explicitly
1 parent 7ac1e40 commit 7753b27

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

client/src/components/__tests__/ToolsTab.test.tsx

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -85,15 +85,11 @@ describe("ToolsTab", () => {
8585
selectedTool: mockTools[1], // Use the tool with integer type
8686
});
8787

88-
// Verify input is rendered as a number input
89-
const input = screen.getByRole("spinbutton") as HTMLInputElement;
90-
expect(input.type).toBe("number"); // Integer type should be treated as number
91-
92-
// Enter an integer value
88+
const input = screen.getByRole("textbox", { name: /count/i }) as HTMLInputElement;
89+
expect(input).toHaveProperty("type", "number");
9390
fireEvent.change(input, { target: { value: "42" } });
9491
expect(input.value).toBe("42");
9592

96-
// Verify the callTool function receives the value as a number
9793
const submitButton = screen.getByRole("button", { name: /run tool/i });
9894
fireEvent.click(submitButton);
9995

0 commit comments

Comments
 (0)