mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-20 12:24:59 +00:00
fix: get_file_mentions skips pure basenames with duplicates
This commit is contained in:
parent
c9d4c8d09b
commit
71446d9f3c
1 changed files with 2 additions and 2 deletions
|
@ -194,8 +194,8 @@ class TestCoder(unittest.TestCase):
|
||||||
mock.return_value = set([str(fname1), str(fname2), str(fname3)])
|
mock.return_value = set([str(fname1), str(fname2), str(fname3)])
|
||||||
coder.repo.get_tracked_files = mock
|
coder.repo.get_tracked_files = mock
|
||||||
|
|
||||||
# Check that file mentions skip files with duplicate basenames
|
# Check that file mentions of a pure basename skips files with duplicate basenames
|
||||||
mentioned = coder.get_file_mentions(f"Check {fname2} and {fname3}")
|
mentioned = coder.get_file_mentions(f"Check {fname2.name} and {fname3}")
|
||||||
self.assertEqual(mentioned, {str(fname3)})
|
self.assertEqual(mentioned, {str(fname3)})
|
||||||
|
|
||||||
# Add a read-only file with same basename
|
# Add a read-only file with same basename
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue