Skip to content

Commit a9a386d

Browse files
committed
docs: document test utils and infra helpers
1 parent 4295329 commit a9a386d

24 files changed

Lines changed: 24 additions & 0 deletions

‎src/infra/approval-handler-runtime.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// Runtime contracts for approval handlers used by execution requests.
12
import type {
23
ChannelApprovalCapability,
34
ChannelApprovalNativeAdapter,

‎src/infra/device-bootstrap.test.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// Tests device bootstrap state creation and persistence.
12
import fs from "node:fs/promises";
23
import path from "node:path";
34
import { afterEach, describe, expect, it, vi } from "vitest";

‎src/infra/exec-approvals-allow-always.test.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// Tests persistent always-allow execution approval rules.
12
import fs from "node:fs";
23
import path from "node:path";
34
import { describe, expect, it } from "vitest";

‎src/infra/exec-safe-bin-semantics.test.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// Tests safe executable detection for shell command approval.
12
import { describe, expect, it } from "vitest";
23
import {
34
listRiskyConfiguredSafeBins,

‎src/infra/home-dir.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// Resolves OpenClaw home and platform-specific config directories.
12
import os from "node:os";
23
import path from "node:path";
34

‎src/infra/os-summary.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// Collects operating system summary facts for diagnostics.
12
import { spawnSync } from "node:child_process";
23
import os from "node:os";
34
import { normalizeOptionalString } from "@openclaw/normalization-core/string-coerce";

‎src/infra/provider-usage.fetch.claude.test.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// Tests Claude provider usage fetch normalization and error handling.
12
import { afterEach, describe, expect, it, vi } from "vitest";
23
import {
34
createProviderUsageFetch,

‎src/infra/push-apns.store.test.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// Tests APNS push token store persistence.
12
import fs from "node:fs/promises";
23
import path from "node:path";
34
import { afterEach, describe, expect, it, vi } from "vitest";

‎src/infra/replace-file.test.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// Tests atomic file replacement helpers and permission handling.
12
import fs from "node:fs/promises";
23
import path from "node:path";
34
import { describe, expect, it } from "vitest";

‎src/infra/semver-compare.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// Compares semantic versions for package and runtime compatibility checks.
12
type ComparableSemver = {
23
major: number;
34
minor: number;

0 commit comments

Comments
 (0)