chore: checkpoint browser tooling and routing updates
This commit is contained in:
@@ -55,7 +55,8 @@ describe('Browser tools', () => {
|
||||
expect(names).toContain('browser.type');
|
||||
expect(names).toContain('browser.content');
|
||||
expect(names).toContain('browser.eval');
|
||||
expect(names).toHaveLength(6);
|
||||
expect(names).toContain('browser.evaluate');
|
||||
expect(names).toHaveLength(7);
|
||||
});
|
||||
|
||||
it('browser.navigate navigates to URL', async () => {
|
||||
@@ -147,6 +148,13 @@ describe('Browser tools', () => {
|
||||
expect(result.output).toBe('hello world');
|
||||
});
|
||||
|
||||
it('browser.evaluate aliases browser.eval behavior', async () => {
|
||||
const tool = getTool('browser.evaluate');
|
||||
const result = await tool.execute({ expression: '1 + 1' });
|
||||
expect(result.success).toBe(true);
|
||||
expect(result.output).toContain('42');
|
||||
});
|
||||
|
||||
it('handles navigation errors gracefully', async () => {
|
||||
mockGoto.mockRejectedValueOnce(new Error('Navigation failed'));
|
||||
const tool = getTool('browser.navigate');
|
||||
|
||||
Reference in New Issue
Block a user