mirror of
https://github.com/QwenLM/qwen-code.git
synced 2025-12-20 08:47:44 +00:00
Added in proper checks for customer tiers in 429/Quota error messaging (#3863)
Co-authored-by: Ioannis Papapanagiotou <iduckhd@hotmail.com>
This commit is contained in:
@@ -67,6 +67,7 @@ interface MockServerConfig {
|
||||
getAccessibility: Mock<() => AccessibilitySettings>;
|
||||
getProjectRoot: Mock<() => string | undefined>;
|
||||
getAllGeminiMdFilenames: Mock<() => string[]>;
|
||||
getUserTier: Mock<() => Promise<string | undefined>>;
|
||||
}
|
||||
|
||||
// Mock @google/gemini-cli-core and its Config class
|
||||
@@ -129,6 +130,7 @@ vi.mock('@google/gemini-cli-core', async (importOriginal) => {
|
||||
getAllGeminiMdFilenames: vi.fn(() => ['GEMINI.md']),
|
||||
setFlashFallbackHandler: vi.fn(),
|
||||
getSessionId: vi.fn(() => 'test-session-id'),
|
||||
getUserTier: vi.fn().mockResolvedValue(undefined),
|
||||
};
|
||||
});
|
||||
return {
|
||||
@@ -155,6 +157,8 @@ vi.mock('./hooks/useAuthCommand', () => ({
|
||||
openAuthDialog: vi.fn(),
|
||||
handleAuthSelect: vi.fn(),
|
||||
handleAuthHighlight: vi.fn(),
|
||||
isAuthenticating: false,
|
||||
cancelAuthentication: vi.fn(),
|
||||
})),
|
||||
}));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user