Files
bDS/tests/renderer/navigation/sidebarUiPersistence.test.ts
2026-02-21 18:02:20 +01:00

15 lines
538 B
TypeScript

import { describe, expect, it } from 'vitest';
import { getPersistedSidebarSection, setPersistedSidebarSection } from '../../../src/renderer/navigation/sidebarUiPersistence';
describe('sidebarUiPersistence', () => {
it('persists and reads section ids by sidebar key', () => {
setPersistedSidebarSection('settings', 'project');
expect(getPersistedSidebarSection('settings')).toBe('project');
});
it('returns null for missing persisted section', () => {
expect(getPersistedSidebarSection('tags')).toBeNull();
});
});