mirror of
https://github.com/moltbot/moltbot.git
synced 2026-05-16 18:34:18 +00:00
test: dedupe launchd handoff mock read
This commit is contained in:
@@ -16,7 +16,7 @@ import { scheduleDetachedLaunchdRestartHandoff } from "./launchd-restart-handoff
|
||||
type SpawnCall = [string, string[], { env: Record<string, string | undefined> }];
|
||||
|
||||
function requireSpawnCall(callIndex = 0): SpawnCall {
|
||||
const call = spawnMock.mock.calls.at(callIndex);
|
||||
const call = spawnMock.mock.calls[callIndex];
|
||||
if (!call) {
|
||||
throw new Error(`expected spawn call ${callIndex}`);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user