refactor: Split language tests into individual cases in test_repomap.py

This commit is contained in:
Paul Gauthier 2025-03-12 15:34:22 -07:00 committed by Paul Gauthier (aider)
parent a83d5ff123
commit 2cc8105e68

View file

@ -283,6 +283,8 @@ class TestRepoMapAllLanguages(unittest.TestCase):
def setUp(self):
self.GPT35 = Model("gpt-3.5-turbo")
# instead of one giant test with a loop, make each language have its own
# test_xxx case that calls self._test_language_repo_map ai!
def test_get_repo_map_all_languages(self):
language_files = {
"c": ("c", "main"),
@ -322,6 +324,7 @@ class TestRepoMapAllLanguages(unittest.TestCase):
fixtures_dir = Path(__file__).parent.parent / "fixtures" / "languages"
dump(len(language_files))
for lang, key_symbol in language_files.items():
self._test_language_repo_map(lang, key_symbol, fixtures_dir)