MCPcopy Create free account
hub / github.com/bcefghj/miniClaudeCode / test_write_new_file

Method test_write_new_file

tests/test_tools.py:97–102  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

95 self.tool = FileWriteTool()
96
97 def test_write_new_file(self):
98 with tempfile.TemporaryDirectory() as tmpdir:
99 path = Path(tmpdir) / "test.txt"
100 result = self.tool.execute({"path": str(path), "content": "hello world"})
101 self.assertFalse(result.is_error)
102 self.assertEqual(path.read_text(), "hello world")
103
104 def test_write_creates_directories(self):
105 with tempfile.TemporaryDirectory() as tmpdir:

Callers

nothing calls this directly

Calls 1

executeMethod · 0.45

Tested by

no test coverage detected