MCPcopy Create free account
hub / github.com/HKUDS/OpenOPC / FakeResponse

Class FakeResponse

tests/test_native_tool_stack.py:185–192  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

183
184 async def test_grep_supports_head_limit_and_offset(self) -> None:
185 root = Path.cwd() / ".tmp-test" / f"native-tool-stack-{uuid.uuid4().hex}"
186 root.mkdir(parents=True, exist_ok=True)
187 try:
188 (root / "src").mkdir()
189 for idx in range(4):
190 (root / "src" / f"f{idx}.txt").write_text(f"VALUE {idx}\n", encoding="utf-8")
191
192 first = await grep("VALUE", path=str(root / "src"), file_glob="*.txt", head_limit=1)
193 second = await grep("VALUE", path=str(root / "src"), file_glob="*.txt", head_limit=1, offset=1)
194 finally:
195 import shutil

Callers 1

getMethod · 0.85

Calls

no outgoing calls

Tested by 1

getMethod · 0.68