From eb9a73bdb0b71b234ab0f411129f3a91ad52c954 Mon Sep 17 00:00:00 2001 From: "Paul Gauthier (aider)" Date: Tue, 29 Oct 2024 14:04:19 -0700 Subject: [PATCH] fix: strip whitespace from file paths before resolving in test commands --- tests/basic/test_commands.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/basic/test_commands.py b/tests/basic/test_commands.py index ec1dcbefb..df8011094 100644 --- a/tests/basic/test_commands.py +++ b/tests/basic/test_commands.py @@ -683,7 +683,7 @@ class TestCommands(TestCase): found_file1 = found_file2 = found_file3 = False for line in commands_text: if line.startswith("/add "): - path = Path(line[5:]).resolve() + path = Path(line[5:].strip()).resolve() if os.path.samefile(str(path), abs_file1): found_file1 = True elif os.path.samefile(str(path), abs_file2):