Skip to content

Garry's Opinionated OpenClaw/Hermes Agent Brain

TypeScript

test(backup): the Windows async-subprocess timeout contract expects private_backup_protection_timeout

garrytane01127702645
diff --git a/test/backup-fsync.serial.test.ts b/test/backup-fsync.serial.test.ts
index e15a94da42..c19accc567 100644
--- a/test/backup-fsync.serial.test.ts
+++ b/test/backup-fsync.serial.test.ts
@@ -176,7 +176,7 @@ process.stdin.on('end', () => {
const pending = privacy.protectNewBackupPath(path, 'file');
expect(callback).toBe(false);
if (mode === 'success') await pending;
- else await expect(pending).rejects.toMatchObject({ code: 'private_backup_path_unavailable' });
+ else await expect(pending).rejects.toMatchObject({ code: mode === 'timeout' ? 'private_backup_protection_timeout' : 'private_backup_path_unavailable' });
expect(calls).toBe(1);
expect(callback).toBe(true);
expect(child).toBeDefined();