26 lines
1.1 KiB
TypeScript
26 lines
1.1 KiB
TypeScript
import { describe, expect, it } from "bun:test";
|
|
import { existsSync } from "node:fs";
|
|
|
|
const disabledServerTools = [
|
|
"get_project_context",
|
|
"list_scada_assets",
|
|
"query_scada_readings",
|
|
];
|
|
|
|
describe("disabled opencode tools", () => {
|
|
it("keeps removed generic server tools disabled while using one typed presentation tool", () => {
|
|
for (const toolName of disabledServerTools) {
|
|
expect(existsSync(`.opencode/tools/${toolName}.ts`)).toBeFalse();
|
|
}
|
|
expect(existsSync(".opencode/tools/server_api_shared.ts")).toBeFalse();
|
|
expect(existsSync(".opencode/tools/web_search.ts")).toBeFalse();
|
|
expect(existsSync(".opencode/tools/geocode.ts")).toBeFalse();
|
|
expect(existsSync(".opencode/tools/present_view.ts")).toBeTrue();
|
|
for (const name of ["locate_features", "zoom_to_map", "show_chart", "view_history", "render_scada_analysis", "clear_scada_analysis"]) {
|
|
expect(existsSync(`.opencode/tools/${name}.ts`)).toBeFalse();
|
|
}
|
|
expect(existsSync(".opencode/tools/frontend_action.ts")).toBeTrue();
|
|
expect(existsSync(".opencode/plugins/tjwater-tools.ts")).toBeTrue();
|
|
});
|
|
});
|