Explorar o código

fix(test): use path.sep in discovery test for cross-platform path matching (#14905)

Luke Parker hai 8 meses
pai
achega
06f25c78f6
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      packages/opencode/test/skill/discovery.test.ts

+ 1 - 1
packages/opencode/test/skill/discovery.test.ts

@@ -77,7 +77,7 @@ describe("Discovery.pull", () => {
   test("downloads reference files alongside SKILL.md", async () => {
   test("downloads reference files alongside SKILL.md", async () => {
     const dirs = await Discovery.pull(CLOUDFLARE_SKILLS_URL)
     const dirs = await Discovery.pull(CLOUDFLARE_SKILLS_URL)
     // find a skill dir that should have reference files (e.g. agents-sdk)
     // find a skill dir that should have reference files (e.g. agents-sdk)
-    const agentsSdk = dirs.find((d) => d.endsWith("/agents-sdk"))
+    const agentsSdk = dirs.find((d) => d.endsWith(path.sep + "agents-sdk"))
     expect(agentsSdk).toBeDefined()
     expect(agentsSdk).toBeDefined()
     if (agentsSdk) {
     if (agentsSdk) {
       const refs = path.join(agentsSdk, "references")
       const refs = path.join(agentsSdk, "references")