feat(editor): add auto close brackets setting

This commit is contained in:
gggaiitx authored and GitHub committed 2026-07-09 09:53:01 +08:00
1 parent 1670fac285
commit 2f134585ea
12 files changed
+145 -4

No files matched your search

+7
View File
@@ -165,6 +165,13 @@ test("defaults Vim mode to off and preserves saved booleans", () => {
assert.equal(normalizeEditorSettings({ vimModeEnabled: "yes" as any }).vimModeEnabled, false);
});
test("defaults auto-close brackets to on and preserves saved booleans", () => {
assert.equal(DEFAULT_EDITOR_SETTINGS.autoCloseBrackets, true);
assert.equal(normalizeEditorSettings({}).autoCloseBrackets, true);
assert.equal(normalizeEditorSettings({ autoCloseBrackets: false }).autoCloseBrackets, false);
assert.equal(normalizeEditorSettings({ autoCloseBrackets: "nope" as any }).autoCloseBrackets, true);
});
test("defaults update notifications to enabled", () => {
assert.equal(DEFAULT_EDITOR_SETTINGS.updateNotificationsEnabled, true);
assert.equal(normalizeEditorSettings({}).updateNotificationsEnabled, true);