Skip to content

Commit e3d8b27

Browse files
committed
test: add AISnapshotStore integration tests
Add integration tests covering snapshot data consistency: content- addressable dedup, snapshot building/back-fill, multi-response restore, file creation/deletion flows, and reset behavior. Expose AISnapshotStore via brackets.test for test window access.
1 parent 3f984b9 commit e3d8b27

4 files changed

Lines changed: 533 additions & 1 deletion

File tree

src/brackets.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -296,6 +296,7 @@ define(function (require, exports, module) {
296296
SidebarTabs: require("view/SidebarTabs"),
297297
SidebarView: require("project/SidebarView"),
298298
WorkingSetView: require("project/WorkingSetView"),
299+
AISnapshotStore: require("core-ai/AISnapshotStore"),
299300
doneLoading: false
300301
};
301302

src/core-ai/AISnapshotStore.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ define(function (require, exports, module) {
3636

3737
// --- Constants ---
3838
const HEARTBEAT_INTERVAL_MS = 60 * 1000;
39-
const STALE_THRESHOLD_MS = 20 * 60 * 1000;
39+
const STALE_THRESHOLD_MS = 10 * 60 * 1000;
4040

4141
// --- Disk store state ---
4242
let _instanceDir; // "<appSupportDir>/instanceData/<instanceId>/"

test/UnitTestSuite.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ define(function (require, exports, module) {
6262
require("spec/KeybindingManager-integ-test");
6363
require("spec/LanguageManager-test");
6464
require("spec/LanguageManager-integ-test");
65+
require("spec/ai-snapshot-test");
6566
require("spec/LowLevelFileIO-test");
6667
require("spec/Metrics-test");
6768
require("spec/MultiRangeInlineEditor-test");

0 commit comments

Comments
 (0)