[verified] feat: add semantic diagram lifecycle

This commit is contained in:
2026-09-03 19:11:50 +00:00
parent 5146b14d43
commit db4129168b
37 changed files with 1626 additions and 58 deletions
+9
View File
@@ -34,6 +34,15 @@ test("CLI rejects partially numeric page indexes", () => {
assert.match(result.stderr, /non-negative integer/);
});
test("CLI help documents lifecycle options and file-free doctor", () => {
const result = spawnSync(process.execPath, ["--import", "tsx", CLI, "--help"], { cwd: resolve("."), encoding: "utf8" });
assert.equal(result.status, 0, result.stdout + result.stderr);
for (const option of ["--spec", "--base", "--strict", "--prune", "--dry-run", "--fail", "--views", "--property", "--from", "--to"]) {
assert.match(result.stdout, new RegExp(option));
}
assert.match(result.stdout, /doctor.*does not require --file/i);
});
test("CLI validate exits non-zero when the validation summary is invalid", () => {
const dir = mkdtempSync(join(tmpdir(), "drawio-cli-validate-test-"));
const input = join(dir, "empty.drawio");