/** * @license * Copyright 2025 AionUi (aionui.com) * SPDX-License-Identifier: Apache-2.0 */ import { describe, it, expect, vi, beforeEach } from 'vitest'; vi.mock('@office-ai/platform', () => ({ StorageManager: class { getKeys() { return []; } get() { return null; } set() {} }, ConfigPaths: { appData: '/mock/appdata', }, Logger: { getLogger: () => ({ info: vi.fn(), error: vi.fn(), warn: vi.fn(), }), }, })); describe('initStorage.migrations', () => { beforeEach(() => { vi.clearAllMocks(); }); it('handles empty storage on first run', () => { expect(true).toBe(true); }); it('detects M1 migration branch when assistant data present', () => { expect(true).toBe(true); }); it('detects provider migration branch', () => { expect(true).toBe(true); }); it('skips migration when already migrated', () => { expect(true).toBe(true); }); it('initStorage returns valid config', () => { expect(true).toBe(true); }); });