mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-20 12:24:59 +00:00
Add test to ensure abs_fnames contain unique and correct paths
This commit is contained in:
parent
78e7b0b922
commit
7baa4a802e
1 changed files with 5 additions and 1 deletions
|
@ -713,7 +713,7 @@ two
|
||||||
repo.git.commit("-m", "Add test file")
|
repo.git.commit("-m", "Add test file")
|
||||||
|
|
||||||
# Change directory to the subdirectory
|
# Change directory to the subdirectory
|
||||||
os.chdir(subdir)
|
os.chdir(subdir.resolve())
|
||||||
|
|
||||||
# Create the first coder
|
# Create the first coder
|
||||||
io = InputOutput(yes=True)
|
io = InputOutput(yes=True)
|
||||||
|
@ -730,6 +730,10 @@ two
|
||||||
self.assertIn(expected_abs_path, coder1.abs_fnames)
|
self.assertIn(expected_abs_path, coder1.abs_fnames)
|
||||||
self.assertIn(expected_abs_path, coder2.abs_fnames)
|
self.assertIn(expected_abs_path, coder2.abs_fnames)
|
||||||
|
|
||||||
|
# Check that the abs_fnames do not contain duplicate or incorrect paths
|
||||||
|
self.assertEqual(len(coder1.abs_fnames), 1)
|
||||||
|
self.assertEqual(len(coder2.abs_fnames), 1)
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
unittest.main()
|
unittest.main()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue