mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-06-16 06:17:21 -07:00
feat(cli): extract QuotaContext and resolve infinite render loop (#24959)
This commit is contained in:
@@ -11,9 +11,9 @@ import {
|
||||
CoreToolCallStatus,
|
||||
ApprovalMode,
|
||||
makeFakeConfig,
|
||||
type SerializableConfirmationDetails,
|
||||
} from '@google/gemini-cli-core';
|
||||
import { type UIState } from './contexts/UIStateContext.js';
|
||||
import type { SerializableConfirmationDetails } from '@google/gemini-cli-core';
|
||||
import { act } from 'react';
|
||||
import { StreamingState } from './types.js';
|
||||
|
||||
@@ -107,15 +107,6 @@ describe('Full Terminal Tool Confirmation Snapshot', () => {
|
||||
constrainHeight: true,
|
||||
isConfigInitialized: true,
|
||||
cleanUiDetailsVisible: true,
|
||||
quota: {
|
||||
userTier: 'PRO',
|
||||
stats: {
|
||||
limits: {},
|
||||
usage: {},
|
||||
},
|
||||
proQuotaRequest: null,
|
||||
validationRequest: null,
|
||||
},
|
||||
pendingHistoryItems: [
|
||||
{
|
||||
id: 2,
|
||||
@@ -145,6 +136,13 @@ describe('Full Terminal Tool Confirmation Snapshot', () => {
|
||||
const { waitUntilReady, lastFrame, generateSvg, unmount } =
|
||||
await renderWithProviders(<App />, {
|
||||
uiState: mockUIState,
|
||||
quotaState: {
|
||||
userTier: 'PRO',
|
||||
stats: {
|
||||
remaining: 100,
|
||||
limit: 1000,
|
||||
},
|
||||
},
|
||||
config: mockConfig,
|
||||
settings: createMockSettings({
|
||||
merged: {
|
||||
|
||||
Reference in New Issue
Block a user