chore: 添加 .oxfmtrc.json 并格式化全部代码
This commit is contained in:
@@ -22,10 +22,7 @@ describe("runInit", () => {
|
||||
expect(existsSync(join(TMP_DIR, ".rune"))).toBe(true);
|
||||
expect(existsSync(join(TMP_DIR, ".rune", "config.yaml"))).toBe(true);
|
||||
|
||||
const content = await readFile(
|
||||
join(TMP_DIR, ".rune", "config.yaml"),
|
||||
"utf-8",
|
||||
);
|
||||
const content = await readFile(join(TMP_DIR, ".rune", "config.yaml"), "utf-8");
|
||||
expect(content).toContain("# Rune 配置文件");
|
||||
expect(content).toContain("stages:");
|
||||
});
|
||||
@@ -46,16 +43,10 @@ describe("runInit", () => {
|
||||
|
||||
it("重复 init 不覆盖 config.yaml", async () => {
|
||||
await runInit(TMP_DIR, ["opencode"]);
|
||||
await writeFile(
|
||||
join(TMP_DIR, ".rune", "config.yaml"),
|
||||
"自定义内容",
|
||||
);
|
||||
await writeFile(join(TMP_DIR, ".rune", "config.yaml"), "自定义内容");
|
||||
|
||||
await runInit(TMP_DIR, ["opencode"]);
|
||||
const content = await readFile(
|
||||
join(TMP_DIR, ".rune", "config.yaml"),
|
||||
"utf-8",
|
||||
);
|
||||
const content = await readFile(join(TMP_DIR, ".rune", "config.yaml"), "utf-8");
|
||||
expect(content).toBe("自定义内容");
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user