Skip to content

The open source coding agent.

TypeScript

test: normalize ripgrep path assertion on windows

Dax Raade30678a088d7
diff --git a/packages/opencode/test/file/ripgrep.test.ts b/packages/opencode/test/file/ripgrep.test.ts
index e0d8e83d164..21bc59dc261 100644
--- a/packages/opencode/test/file/ripgrep.test.ts
+++ b/packages/opencode/test/file/ripgrep.test.ts
@@ -51,7 +51,7 @@ describe("file.ripgrep", () => {
})
expect(hits.length).toBe(1)
- expect(hits[0]?.path.text).toBe("match.ts")
+ expect(path.basename(hits[0]?.path.text ?? "")).toBe("match.ts")
expect(hits[0]?.line_number).toBe(1)
expect(hits[0]?.lines.text).toContain("needle")
})