mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-04-22 11:04:42 -07:00
test(cli): update tests and snapshots for enableCompactToolOutput
- Update all UI snapshots to synchronize with the new 'compact' default and minor layout tweaks. - Update legacy UI regression tests to explicitly disable 'enableCompactToolOutput' to verify boxed layout behavior (overflows, sticky headers). - Refactor 'useGeminiStream.test.tsx' to resolve TypeErrors and use consistent mock settings supporting the new UI options. - Fix EPERM failures by using 'os.tmpdir()' in a2a-server and CLI theme tests to resolve macOS Seatbelt issues.
This commit is contained in:
@@ -20,6 +20,8 @@ import {
|
||||
import { createMockMessageBus } from '@google/gemini-cli-core/src/test-utils/mock-message-bus.js';
|
||||
import type { Config, Storage } from '@google/gemini-cli-core';
|
||||
import { expect, vi } from 'vitest';
|
||||
import os from 'node:os';
|
||||
import path from 'node:path';
|
||||
|
||||
export function createMockConfig(
|
||||
overrides: Partial<Config> = {},
|
||||
@@ -43,8 +45,8 @@ export function createMockConfig(
|
||||
getCheckpointingEnabled: vi.fn().mockReturnValue(false),
|
||||
// eslint-disable-next-line @typescript-eslint/no-unsafe-type-assertion
|
||||
storage: {
|
||||
getProjectTempDir: () => '/tmp',
|
||||
getProjectTempCheckpointsDir: () => '/tmp/checkpoints',
|
||||
getProjectTempDir: () => os.tmpdir(),
|
||||
getProjectTempCheckpointsDir: () => path.join(os.tmpdir(), 'checkpoints'),
|
||||
} as Storage,
|
||||
getTruncateToolOutputThreshold: () =>
|
||||
DEFAULT_TRUNCATE_TOOL_OUTPUT_THRESHOLD,
|
||||
|
||||
Reference in New Issue
Block a user