test: isolate skill-tools and mcp-index tests to prevent mock contamination

Moves test files with mock.module() calls into zauc-mocks-* directories
to prevent process-global mock pollution affecting subsequent tests.

- src/tools/skill/tools.test.ts -> zauc-mocks-skill-tools/
- src/mcp/index.test.ts -> zauc-mocks-mcp-index/

Fixes remaining 21 CI failures (resolveSubagentExecution + slashcommand).
This commit is contained in:
YeonGyu-Kim
2026-04-04 20:49:47 +09:00
parent 9d8d48f06c
commit ba26b6f29d
2 changed files with 3 additions and 3 deletions
@@ -1,9 +1,9 @@
import { afterAll, beforeEach, describe, expect, it, mock, spyOn } from "bun:test"
import type { ToolContext } from "@opencode-ai/plugin/tool"
import * as fs from "node:fs"
import { SkillMcpManager } from "../../features/skill-mcp-manager"
import type { LoadedSkill } from "../../features/opencode-skill-loader/types"
import type { CommandInfo } from "../slashcommand/types"
import { SkillMcpManager } from "../../../features/skill-mcp-manager"
import type { LoadedSkill } from "../../../features/opencode-skill-loader/types"
import type { CommandInfo } from "../../slashcommand/types"
import type { Tool as McpTool } from "@modelcontextprotocol/sdk/types.js"
const originalReadFileSync = fs.readFileSync.bind(fs)