mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-22 21:34:59 +00:00
cleanup
This commit is contained in:
parent
79030d968f
commit
a88b2a70e8
2 changed files with 23 additions and 24 deletions
|
@ -89,17 +89,21 @@ class TestCommands(TestCase):
|
|||
|
||||
# Create a directory and add files to it
|
||||
os.mkdir("test_dir")
|
||||
os.mkdir("test_dir/another_dir")
|
||||
with open("test_dir/test_file1.txt", "w") as f:
|
||||
f.write("Test file 1")
|
||||
with open("test_dir/test_file2.txt", "w") as f:
|
||||
f.write("Test file 2")
|
||||
with open("test_dir/another_dir/test_file.txt", "w") as f:
|
||||
f.write("Test file 3")
|
||||
|
||||
# Call the cmd_add method with a directory
|
||||
commands.cmd_add("test_dir")
|
||||
commands.cmd_add("test_dir test_dir/test_file2.txt")
|
||||
|
||||
# Check if the files have been added to the chat session
|
||||
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.assertIn(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
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue