Skip to content

Commit a73074e

Browse files
Preserve runtime external auth snapshots
1 parent 1f2ada4 commit a73074e

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

src/agents/auth-profiles.store.save.test.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -633,6 +633,12 @@ describe("saveAuthProfileStore", () => {
633633
expect(snapshotAfterRuntimeBackedSave?.usageStats?.[externalProfileId]?.lastUsed).toBe(789);
634634

635635
saveAuthProfileStore(runtimeWithoutExternal, agentDir);
636+
const persistedAfterDiskBackedSave = JSON.parse(
637+
await fs.readFile(resolveAuthStorePath(agentDir), "utf8"),
638+
) as {
639+
profiles: Record<string, unknown>;
640+
};
641+
expect(persistedAfterDiskBackedSave.profiles[externalProfileId]).toBeUndefined();
636642
const snapshotAfterDiskBackedSave = getRuntimeAuthProfileStoreSnapshot(agentDir);
637643
expect(snapshotAfterDiskBackedSave?.runtimeExternalProfileIds).toEqual([externalProfileId]);
638644
expect(snapshotAfterDiskBackedSave?.runtimeExternalProfileIdsAuthoritative).toBe(true);

0 commit comments

Comments
 (0)