test(gateway): pass the Gateway scheduler to the config-commit projection reloader

#160375 (28f0d26b43) made startGatewayConfigReloader require a scheduler; #160274 (cb3755a343) landed a new test calling it without one, so the gateway-root test typecheck fails on main (TS2741: Property 'scheduler' is missing). Supply the shared test scheduler like the other config-reload tests. Proof: tsgo test/tsconfig/tsconfig.core.test.gateway-root.json passes; the file passes (1 test); targeted oxlint and diff check pass.
This commit is contained in:
Peter Steinberger 2026-09-28 11:13:48 -07:00
parent 9d330a0a7f
commit 4bd105408c

View file

@ -15,6 +15,7 @@ import {
recordAgentDatabaseAdmissions,
} from "../state/agent-database-admission.js";
import { resolveOpenClawAgentSqlitePath } from "../state/openclaw-agent-db.js";
import { createTestGatewayScheduler } from "../test-utils/gateway-scheduler-clock.js";
import { withOpenClawTestState } from "../test-utils/openclaw-test-state.js";
import { startGatewayConfigReloader, type GatewayReloadPlan } from "./config-reload.js";
import { createWatcherMock } from "./config-reload.watcher.test-support.js";
@ -74,6 +75,7 @@ it("retains resident rows across projection-neutral commits and unchanged admiss
return "applied";
};
const reloader = startGatewayConfigReloader({
scheduler: createTestGatewayScheduler("fake-timers"),
initialConfig: cfg,
initialCompareConfig: initial.sourceConfig,
initialSnapshotRawHash: initial.hash ?? null,