docs: document rescue and trajectory tests

This commit is contained in:
Peter Steinberger
2026-06-04 20:29:59 -04:00
parent d8326f13c3
commit 1bdf210b43
23 changed files with 23 additions and 0 deletions

View File

@@ -1,3 +1,4 @@
// Configured Crestodian assistant tests cover config-driven assistant behavior.
import { describe, expect, it, vi } from "vitest";
import { planCrestodianCommandWithConfiguredModel } from "./assistant.js";

View File

@@ -1,3 +1,4 @@
// Crestodian assistant tests cover assistant-driven rescue message generation.
import { describe, expect, it, vi } from "vitest";
import type { RunCliAgentParams } from "../agents/cli-runner/types.js";
import type { RunEmbeddedAgentParams } from "../agents/embedded-agent-runner/run/params.js";

View File

@@ -1,3 +1,4 @@
// Crestodian audit tests cover filesystem-backed rescue audit scenarios.
import fs from "node:fs/promises";
import os from "node:os";
import path from "node:path";

View File

@@ -1,3 +1,4 @@
// Crestodian test helpers build runtime environments for rescue tests.
import type { RuntimeEnv } from "../runtime.js";
/**

View File

@@ -1,3 +1,4 @@
// Crestodian tests cover main rescue and audit command behavior.
import { describe, expect, it } from "vitest";
import { runCrestodian } from "./crestodian.js";
import { createCrestodianTestRuntime } from "./crestodian.test-helpers.js";

View File

@@ -1,3 +1,4 @@
// Crestodian operation tests cover rescue operation planning and execution.
import fs from "node:fs/promises";
import os from "node:os";
import path from "node:path";

View File

@@ -1,3 +1,4 @@
// Crestodian overview tests cover summary output for rescue diagnostics.
import { describe, expect, it } from "vitest";
import type { ConfigFileSnapshot, OpenClawConfig } from "../config/config.js";
import {

View File

@@ -1,3 +1,4 @@
// Crestodian probe tests cover timeout handling and probe result formatting.
import { MAX_TIMER_TIMEOUT_MS } from "@openclaw/normalization-core/number-coercion";
import { afterEach, describe, expect, it, vi } from "vitest";
import { probeGatewayUrl, probeLocalCommand } from "./probes.js";

View File

@@ -1,3 +1,4 @@
// Crestodian live rescue channel tests cover live-channel rescue message delivery.
import fs from "node:fs/promises";
import os from "node:os";
import path from "node:path";

View File

@@ -1,3 +1,4 @@
// Crestodian rescue message tests cover generated rescue message content.
import fs from "node:fs/promises";
import os from "node:os";
import path from "node:path";

View File

@@ -1,3 +1,4 @@
// Crestodian rescue policy tests cover eligibility and safety decisions.
import { describe, expect, it } from "vitest";
import type { OpenClawConfig } from "../config/types.openclaw.js";
import { resolveCrestodianRescuePolicy } from "./rescue-policy.js";

View File

@@ -1,3 +1,4 @@
// Crestodian TUI backend tests cover rescue status integration with the TUI backend.
import { describe, expect, it } from "vitest";
import type { RuntimeEnv } from "../runtime.js";
import type { CrestodianOverview } from "./overview.js";

View File

@@ -1,3 +1,4 @@
// Trajectory cleanup tests cover retention pruning of trajectory artifacts.
import fs from "node:fs/promises";
import path from "node:path";
import { describe, expect, it } from "vitest";

View File

@@ -1,3 +1,4 @@
// Trajectory cleanup helpers remove old trajectory files by retention policy.
import fs from "node:fs";
import path from "node:path";
import { isRecord } from "@openclaw/normalization-core/record-coerce";

View File

@@ -1,3 +1,4 @@
// Trajectory command export helpers implement CLI export behavior.
import fsp from "node:fs/promises";
import path from "node:path";
import { pathExists } from "../infra/fs-safe.js";

View File

@@ -1,3 +1,4 @@
// Trajectory export tests cover packaged trajectory output and metadata.
import fs from "node:fs";
import os from "node:os";
import path from "node:path";

View File

@@ -1,3 +1,4 @@
// Trajectory export helpers package recorded trajectories for diagnostics.
import fsp from "node:fs/promises";
import path from "node:path";
import { isRecord } from "@openclaw/normalization-core/record-coerce";

View File

@@ -1,3 +1,4 @@
// Trajectory metadata tests cover metadata capture and normalization.
import { afterEach, describe, expect, it, vi } from "vitest";
import { REDACTED_SENTINEL } from "../config/redact-snapshot.js";
import {

View File

@@ -1,3 +1,4 @@
// Trajectory metadata helpers capture environment metadata for trajectory files.
import { resolveStateDir } from "../config/paths.js";
import { redactConfigObject } from "../config/redact-snapshot.js";
import type { SessionSystemPromptReport } from "../config/sessions/types.js";

View File

@@ -1,3 +1,4 @@
// Trajectory path helpers resolve storage paths for trajectory artifacts.
import fs from "node:fs";
import path from "node:path";
import { resolveHomeRelativePath } from "../infra/home-dir.js";

View File

@@ -1,3 +1,4 @@
// Trajectory runtime file helpers create and append trajectory log files.
import fsp from "node:fs/promises";
import path from "node:path";
import {

View File

@@ -1,3 +1,4 @@
// Trajectory runtime tests cover event recording and runtime file handling.
import fs from "node:fs";
import os from "node:os";
import path from "node:path";

View File

@@ -1,3 +1,4 @@
// Trajectory runtime records runtime events into trajectory log files.
import fs from "node:fs";
import path from "node:path";
import { sanitizeDiagnosticPayload } from "../agents/payload-redaction.js";