refactor(cli,core): foundational layout, identity management, and type safety (#23286)

This commit is contained in:
Jarrod Whelan
2026-03-23 18:49:51 -07:00
committed by GitHub
parent 57a66f5f0d
commit 89ca78837e
31 changed files with 477 additions and 182 deletions
@@ -6,17 +6,30 @@
import { renderHook } from '../../test-utils/render.js';
import { act } from 'react';
import { describe, it, expect, vi, beforeEach, type Mock } from 'vitest';
import {
describe,
it,
expect,
vi,
beforeEach,
afterEach,
type Mock,
} from 'vitest';
import { useInlineEditBuffer } from './useInlineEditBuffer.js';
describe('useEditBuffer', () => {
let mockOnCommit: Mock;
beforeEach(() => {
vi.useFakeTimers();
vi.clearAllMocks();
mockOnCommit = vi.fn();
});
afterEach(() => {
vi.useRealTimers();
});
it('should initialize with empty state', async () => {
const { result } = await renderHook(() =>
useInlineEditBuffer({ onCommit: mockOnCommit }),