From 93866ebe1762cbd00bd2902d6ab46072d90f4ce5 Mon Sep 17 00:00:00 2001 From: Paul Gauthier Date: Mon, 10 Jul 2023 15:19:30 -0700 Subject: [PATCH] test name --- tests/test_commands.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/tests/test_commands.py b/tests/test_commands.py index 297fd9a30..3590c65e5 100644 --- a/tests/test_commands.py +++ b/tests/test_commands.py @@ -79,7 +79,7 @@ class TestCommands(TestCase): # Check if no files have been added to the chat session self.assertEqual(len(coder.abs_fnames), 0) - def test_cmd_add_directory(self): + def test_cmd_add_drop_directory(self): # Initialize the Commands and InputOutput objects io = InputOutput(pretty=False, yes=True) from aider.coders import Coder @@ -105,8 +105,12 @@ class TestCommands(TestCase): self.assertIn(str(Path("test_dir/test_file2.txt").resolve()), coder.abs_fnames) self.assertIn(str(Path("test_dir/another_dir/test_file.txt").resolve()), coder.abs_fnames) - commands.cmd_drop("test_dir") - self.assertEqual(len(coder.abs_fnames), 0) + commands.cmd_drop("test_dir/another_dir") + self.assertIn(str(Path("test_dir/test_file1.txt").resolve()), coder.abs_fnames) + self.assertIn(str(Path("test_dir/test_file2.txt").resolve()), coder.abs_fnames) + self.assertNotIn( + str(Path("test_dir/another_dir/test_file.txt").resolve()), coder.abs_fnames + ) def test_cmd_drop_with_glob_patterns(self): # Initialize the Commands and InputOutput objects