mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-21 12:55:00 +00:00
fix: Rename cmd_read to cmd_read_only
This commit is contained in:
parent
076db26854
commit
f9471fc5b6
1 changed files with 5 additions and 5 deletions
|
@ -551,7 +551,7 @@ class TestCommands(TestCase):
|
|||
test_file.write_text("Test content")
|
||||
|
||||
# Add the file as read-only
|
||||
commands.cmd_read(str(test_file))
|
||||
commands.cmd_read_only(str(test_file))
|
||||
|
||||
# Verify it's in abs_read_only_fnames
|
||||
self.assertTrue(
|
||||
|
@ -787,7 +787,7 @@ class TestCommands(TestCase):
|
|||
self.assertNotIn(fname2, str(coder.abs_fnames))
|
||||
self.assertNotIn(fname3, str(coder.abs_fnames))
|
||||
|
||||
def test_cmd_read(self):
|
||||
def test_cmd_read_only(self):
|
||||
with GitTemporaryDirectory():
|
||||
io = InputOutput(pretty=False, yes=False)
|
||||
coder = Coder.create(self.GPT35, None, io)
|
||||
|
@ -798,7 +798,7 @@ class TestCommands(TestCase):
|
|||
test_file.write_text("Test content")
|
||||
|
||||
# Test the /read command
|
||||
commands.cmd_read(str(test_file))
|
||||
commands.cmd_read_only(str(test_file))
|
||||
|
||||
# Check if the file was added to abs_read_only_fnames
|
||||
self.assertTrue(
|
||||
|
@ -819,7 +819,7 @@ class TestCommands(TestCase):
|
|||
)
|
||||
)
|
||||
|
||||
def test_cmd_read_with_external_file(self):
|
||||
def test_cmd_read_only_with_external_file(self):
|
||||
with tempfile.NamedTemporaryFile(mode="w", delete=False) as external_file:
|
||||
external_file.write("External file content")
|
||||
external_file_path = external_file.name
|
||||
|
@ -831,7 +831,7 @@ class TestCommands(TestCase):
|
|||
commands = Commands(io, coder)
|
||||
|
||||
# Test the /read command with an external file
|
||||
commands.cmd_read(external_file_path)
|
||||
commands.cmd_read_only(external_file_path)
|
||||
|
||||
# Check if the external file was added to abs_read_only_fnames
|
||||
real_external_file_path = os.path.realpath(external_file_path)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue