mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-21 12:55:00 +00:00
fix: use os.path.join for cross-platform path handling in tests
This commit is contained in:
parent
e3a3a55dd5
commit
bf60e58d5b
1 changed files with 2 additions and 4 deletions
|
@ -1037,7 +1037,7 @@ class TestCommands(TestCase):
|
|||
os.chdir(subdir)
|
||||
|
||||
# Test the /read-only command using git_root referenced name
|
||||
commands.cmd_read_only("subdir/test_read_only_file.txt")
|
||||
commands.cmd_read_only(os.path.join("subdir", "test_read_only_file.txt"))
|
||||
|
||||
# Check if the file was added to abs_read_only_fnames
|
||||
self.assertTrue(
|
||||
|
@ -1047,10 +1047,8 @@ class TestCommands(TestCase):
|
|||
)
|
||||
)
|
||||
|
||||
# ai: these filenames use / so tests fail on windows; fix the one above and below to be portable!
|
||||
|
||||
# Test dropping the read-only file using git_root referenced name
|
||||
commands.cmd_drop("subdir/test_read_only_file.txt")
|
||||
commands.cmd_drop(os.path.join("subdir", "test_read_only_file.txt"))
|
||||
|
||||
# Check if the file was removed from abs_read_only_fnames
|
||||
self.assertFalse(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue