mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-21 12:55:00 +00:00
fix: update test to use os.path.samefile for path comparison
This commit is contained in:
parent
56f3220d4c
commit
ccdd333ba3
1 changed files with 6 additions and 1 deletions
|
@ -845,7 +845,12 @@ class TestCommands(TestCase):
|
|||
read_only_files = {coder.get_rel_fname(f) for f in coder.abs_read_only_fnames}
|
||||
|
||||
self.assertEqual(added_files, {str(Path("internal1.txt"))})
|
||||
self.assertEqual(read_only_files, {external_file1_path, external_file2_path})
|
||||
self.assertTrue(
|
||||
all(
|
||||
any(os.path.samefile(external_path, fname) for fname in read_only_files)
|
||||
for external_path in [external_file1_path, external_file2_path]
|
||||
)
|
||||
)
|
||||
|
||||
# Clean up
|
||||
Path(session_file).unlink()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue