mirror of
https://github.com/FoundationAgents/MetaGPT.git
synced 2026-04-27 17:56:23 +02:00
fix tests
This commit is contained in:
parent
fee24bbdfb
commit
d2233beff4
1 changed files with 2 additions and 1 deletions
|
|
@ -2,11 +2,12 @@ from typing import Optional
|
|||
|
||||
from metagpt.logs import log_llm_stream, logger
|
||||
from metagpt.provider.openai_api import OpenAILLM
|
||||
from tests.metagpt.provider.mock_llm_config import mock_llm_config
|
||||
|
||||
|
||||
class MockLLM(OpenAILLM):
|
||||
def __init__(self, allow_open_api_call):
|
||||
super().__init__()
|
||||
super().__init__(mock_llm_config)
|
||||
self.allow_open_api_call = allow_open_api_call
|
||||
self.rsp_cache: dict = {}
|
||||
self.rsp_candidates: list[dict] = [] # a test can have multiple calls with the same llm, thus a list
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue