浏览代码

fix the failed unit test. (#2405)

Signed-off-by: ifuryst <ifuryst@gmail.com>
Leo 1 年之前
父节点
当前提交
7fcd14a055
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      frontend/src/components/modals/settings/SettingsModal.test.tsx

+ 2 - 2
frontend/src/components/modals/settings/SettingsModal.test.tsx

@@ -24,7 +24,7 @@ vi.mock("#/services/settings", async (importOriginal) => ({
   ...(await importOriginal<typeof import("#/services/settings")>()),
   getSettings: vi.fn().mockReturnValue({
     LLM_MODEL: "gpt-4o",
-    AGENT: "MonologueAgent",
+    AGENT: "CodeActAgent",
     LANGUAGE: "en",
     LLM_API_KEY: "sk-...",
   }),
@@ -196,7 +196,7 @@ describe("SettingsModal", () => {
         await userEvent.click(saveButton);
       });
 
-      expect(toastSpy).toHaveBeenCalledTimes(3);
+      expect(toastSpy).toHaveBeenCalledTimes(2);
     });
 
     it("should change the language", async () => {