MCPcopy Index your code
hub / github.com/scriptscat/scriptcat / createTestZip

Function createTestZip

src/pkg/utils/skill.test.ts:7–13  ·  view source on GitHub ↗
(files: Record<string, string>)

Source from the content-addressed store, hash-verified

5
6// 辅助函数:创建测试用 ZIP ArrayBuffer
7async function createTestZip(files: Record<string, string>): Promise<ArrayBuffer> {
8 const zip = createJSZip();
9 for (const [path, content] of Object.entries(files)) {
10 zip.file(path, content);
11 }
12 return zip.generateAsync({ type: "arraybuffer" });
13}
14
15describe("parseSkillMd", () => {
16 it("应正确解析完整的 SKILL.md", () => {

Callers 1

skill.test.tsFile · 0.85

Calls 4

createJSZipFunction · 0.90
entriesMethod · 0.80
fileMethod · 0.80
generateAsyncMethod · 0.80

Tested by

no test coverage detected