mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-21 21:04:59 +00:00
Assert that the file exists before iterating through commits.
This commit is contained in:
parent
d09e85adc2
commit
f722394db6
1 changed files with 5 additions and 0 deletions
|
@ -380,6 +380,11 @@ class TestCoder(unittest.TestCase):
|
||||||
io = InputOutput(yes=True)
|
io = InputOutput(yes=True)
|
||||||
coder = Coder.create(models.GPT4, "diff", io=io, fnames=[str(fname)])
|
coder = Coder.create(models.GPT4, "diff", io=io, fnames=[str(fname)])
|
||||||
|
|
||||||
|
self.assertTrue(fname.exists())
|
||||||
|
|
||||||
|
### TODO: assert that the next line raises git.exc.GitCommandError
|
||||||
|
repo.iter_commits(repo.active_branch.name)
|
||||||
|
|
||||||
def mock_send(*args, **kwargs):
|
def mock_send(*args, **kwargs):
|
||||||
coder.partial_response_content = f"""
|
coder.partial_response_content = f"""
|
||||||
Do this:
|
Do this:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue