21 lines
731 B
TypeScript
21 lines
731 B
TypeScript
import { describe, expect, it } from "bun:test";
|
|
import { readFile } from "node:fs/promises";
|
|
import { join } from "node:path";
|
|
|
|
const projectRoot = join(import.meta.dir, "../..");
|
|
|
|
describe("supply Agent identity", () => {
|
|
it("keeps the primary instruction scoped to validated supply data", async () => {
|
|
const instruction = await readFile(
|
|
join(projectRoot, ".opencode/agents/instruction.md"),
|
|
"utf8",
|
|
);
|
|
|
|
expect(instruction).toContain("TJWater 实验性供水数据 Agent");
|
|
expect(instruction).toContain("供水事件数据边界");
|
|
expect(instruction).not.toContain("source/");
|
|
expect(instruction).not.toContain("排水");
|
|
expect(instruction).not.toContain("雨污混接");
|
|
});
|
|
});
|