mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-20 12:24:59 +00:00
refactor: remove redundant get_system_info method and update related test
This commit is contained in:
parent
45855bd96c
commit
8cfdcbd976
2 changed files with 2 additions and 8 deletions
|
@ -919,12 +919,6 @@ class Coder:
|
||||||
|
|
||||||
return platform_text
|
return platform_text
|
||||||
|
|
||||||
def get_system_info(self):
|
|
||||||
system_info = self.get_platform_info()
|
|
||||||
if self.chat_language:
|
|
||||||
system_info += f"- Chat language: {self.chat_language}\n"
|
|
||||||
return system_info
|
|
||||||
|
|
||||||
def fmt_system_prompt(self, prompt):
|
def fmt_system_prompt(self, prompt):
|
||||||
lazy_prompt = self.gpt_prompts.lazy_prompt if self.main_model.lazy else ""
|
lazy_prompt = self.gpt_prompts.lazy_prompt if self.main_model.lazy else ""
|
||||||
platform_text = self.get_platform_info()
|
platform_text = self.get_platform_info()
|
||||||
|
|
|
@ -628,8 +628,8 @@ class TestMain(TestCase):
|
||||||
output=DummyOutput(),
|
output=DummyOutput(),
|
||||||
return_coder=True,
|
return_coder=True,
|
||||||
)
|
)
|
||||||
system_info = coder.get_system_info()
|
system_info = coder.get_platform_info()
|
||||||
self.assertIn("Chat language: Spanish", system_info)
|
self.assertIn("Spanish", system_info)
|
||||||
|
|
||||||
@patch("git.Repo.init")
|
@patch("git.Repo.init")
|
||||||
def test_main_exit_with_git_command_not_found(self, mock_git_init):
|
def test_main_exit_with_git_command_not_found(self, mock_git_init):
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue