Skip to content

Commit d451331

Browse files
committed
test: Update tests with new playwright_iframe_fill tool
1 parent c098bd3 commit d451331

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

src/__tests__/toolHandler.test.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,14 @@ jest.mock('playwright', () => {
1515
const mockOn = jest.fn();
1616
const mockIsClosed = jest.fn().mockReturnValue(false);
1717

18-
// Mock iframe click
18+
// Mock iframe click and fill
1919
const mockIframeClick = jest.fn().mockImplementation(() => Promise.resolve());
20+
const mockIframeFill = jest.fn().mockImplementation(() => Promise.resolve());
2021
const mockIframeLocator = jest.fn().mockReturnValue({
21-
click: mockIframeClick
22+
click: mockIframeClick,
23+
fill: mockIframeFill
2224
});
23-
25+
2426
// Mock locator
2527
const mockLocatorClick = jest.fn().mockImplementation(() => Promise.resolve());
2628
const mockLocatorFill = jest.fn().mockImplementation(() => Promise.resolve());

src/tools/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ export const BROWSER_TOOLS = [
88
"playwright_screenshot",
99
"playwright_click",
1010
"playwright_iframe_click",
11+
"playwright_iframe_fill",
1112
"playwright_fill",
1213
"playwright_select",
1314
"playwright_hover",

0 commit comments

Comments
 (0)