chore: disable external and frontend tools
This commit is contained in:
@@ -3,23 +3,8 @@ import { describe, expect, it } from "bun:test";
|
||||
import { toUiEnvelopeFromToolCall } from "../../src/uiEnvelope/fromToolCall.js";
|
||||
|
||||
describe("toUiEnvelopeFromToolCall", () => {
|
||||
it("maps zoom_to_map calls to map action envelopes", () => {
|
||||
const envelope = toUiEnvelopeFromToolCall({
|
||||
tool: "zoom_to_map",
|
||||
reason: "定位 SCADA 资产附近位置",
|
||||
params: { x: 121.47, y: 31.23, source_crs: "EPSG:4326" },
|
||||
});
|
||||
|
||||
expect(envelope).toMatchObject({
|
||||
kind: "map_action",
|
||||
action: "zoom_to_map",
|
||||
surface: "map_overlay",
|
||||
params: { x: 121.47, y: 31.23, source_crs: "EPSG:4326" },
|
||||
fallbackText: "定位 SCADA 资产附近位置",
|
||||
});
|
||||
});
|
||||
|
||||
it("does not map removed visual tools", () => {
|
||||
expect(toUiEnvelopeFromToolCall({ tool: "zoom_to_map", params: {} })).toBeNull();
|
||||
expect(toUiEnvelopeFromToolCall({ tool: "show_chart", params: {} })).toBeNull();
|
||||
expect(toUiEnvelopeFromToolCall({ tool: "view_scada", params: { asset_ids: ["A-1"] } })).toBeNull();
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user