Skip to content

Commit cf340ce

Browse files
fix(test): route #824 install teardown through removeTree
After rebasing onto main, the Codex add-only install tests still used bare recursive rm in finally blocks; the remove-tree lint gate correctly failed.
1 parent 3d6ba6c commit cf340ce

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

‎packages/agent-bundle/tests/install.test.ts‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -735,7 +735,7 @@ it('preserves Codex nested MCP overrides and concurrent config edits across enab
735735
expect(config).toContain('model = "changed-by-add"');
736736
expect(config).not.toContain('model = "keep-me"');
737737
} finally {
738-
await rm(fixture.cleanupRoot, { force: true, recursive: true });
738+
await removeTree(fixture.cleanupRoot);
739739
}
740740
});
741741

@@ -778,7 +778,7 @@ it('keeps Codex plugin settings when add fails during enabled replace', async ()
778778
expect(config).toContain(`${codexPluginNestedMcp}\nenabled = false`);
779779
expect(config).toContain('model = "changed-by-add"');
780780
} finally {
781-
await rm(fixture.cleanupRoot, { force: true, recursive: true });
781+
await removeTree(fixture.cleanupRoot);
782782
}
783783
});
784784

@@ -826,7 +826,7 @@ it('does not plugin-remove after a failed Codex replace receipt write', async ()
826826
expect(config).not.toBe(prior);
827827
} finally {
828828
writeReceipt.mockRestore();
829-
await rm(fixture.cleanupRoot, { force: true, recursive: true });
829+
await removeTree(fixture.cleanupRoot);
830830
}
831831
});
832832

@@ -889,7 +889,7 @@ it('fails Codex replace closed for disabled or unknown enablement before any mut
889889
expect(unreadable.calls.map((call) => call.args.join(' '))).toEqual(['plugin list --json']);
890890
expect((await stat(join(codexHome, 'config.toml'))).isDirectory()).toBe(true);
891891
} finally {
892-
await rm(fixture.cleanupRoot, { force: true, recursive: true });
892+
await removeTree(fixture.cleanupRoot);
893893
}
894894
});
895895

0 commit comments

Comments
 (0)