import assert from "node:assert/strict"; import { readFileSync } from "node:fs"; import { resolve } from "node:path"; import { fileURLToPath } from "node:url"; const webuiRoot = resolve(fileURLToPath(new URL("..", import.meta.url))); const read = (path) => readFileSync(resolve(webuiRoot, path), "utf8"); const settings = read("src/features/settings/SettingsPage.tsx"); const retention = read("src/features/privacy/RetentionPolicyManagement.tsx"); const credentials = read("src/components/CredentialEnvelopeManager.tsx"); assert.match(settings, /contextId: "core\.settings"/, "settings expose stable contextual documentation"); assert.match(settings, /There are no unsaved profile changes\./, "profile save explains its clean state"); assert.match(settings, /There are no unsaved interface changes\./, "preference save explains its clean state"); assert.match(retention, /