mirror of
https://github.com/openclaw/openclaw.git
synced 2026-08-25 11:55:47 -06:00
f72782d87b
* test: restore auth persistence integrity
Restore the SQLite-backed auth wizard assertions traced to 43ea501f38 and consolidate duplicated message-action and temp-directory fixtures.
* test: support npm 12 pack results
10 lines
410 B
TypeScript
10 lines
410 B
TypeScript
// Temporary repo helper creates Git repositories for integration tests.
|
|
import fs from "node:fs";
|
|
import path from "node:path";
|
|
|
|
/** Write formatted JSON to a path, creating parent directories. */
|
|
export function writeJsonFile(filePath: string, value: unknown): void {
|
|
fs.mkdirSync(path.dirname(filePath), { recursive: true });
|
|
fs.writeFileSync(filePath, `${JSON.stringify(value, null, 2)}\n`, "utf8");
|
|
}
|