diff options
| author | Dax Raad <[email protected]> | 2025-05-26 14:09:17 -0400 |
|---|---|---|
| committer | Dax Raad <[email protected]> | 2025-05-26 14:09:17 -0400 |
| commit | 80555f13e052443dc9dc67811bf782a3146de512 (patch) | |
| tree | 9219001cf50a23032ad968fc036053dfd223b65e /js/test/tool/tool.test.ts | |
| parent | 113c49457fd6e37d517e2d212e2e6eb21084b4fb (diff) | |
| download | opencode-80555f13e052443dc9dc67811bf782a3146de512.tar.gz opencode-80555f13e052443dc9dc67811bf782a3146de512.zip | |
more tools
Diffstat (limited to 'js/test/tool/tool.test.ts')
| -rw-r--r-- | js/test/tool/tool.test.ts | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/js/test/tool/tool.test.ts b/js/test/tool/tool.test.ts index 4e9daf152..8f69f7b59 100644 --- a/js/test/tool/tool.test.ts +++ b/js/test/tool/tool.test.ts @@ -1,6 +1,7 @@ import { describe, expect, test } from "bun:test"; import { App } from "../../src/app"; import { glob } from "../../src/tool/glob"; +import { ls } from "../../src/tool/ls"; describe("tool.glob", () => { test("truncate", async () => { @@ -35,3 +36,20 @@ describe("tool.glob", () => { }); }); }); + +describe("tool.ls", () => { + test("basic", async () => { + const result = await App.provide({ directory: process.cwd() }, async () => { + return await ls.execute( + { + path: ".", + }, + { + toolCallId: "test", + messages: [], + }, + ); + }); + expect(result.output).toMatchSnapshot(); + }); +}); |
