test_upload_download_roundtrip() — langchain Function Reference
Architecture documentation for the test_upload_download_roundtrip() function in sandboxes.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD efaa63f2_66e7_f8de_f995_2d111f40adb6["test_upload_download_roundtrip()"] 44713bb8_64c7_b8af_22f9_b6db34868592["SandboxIntegrationTests"] efaa63f2_66e7_f8de_f995_2d111f40adb6 -->|defined in| 44713bb8_64c7_b8af_22f9_b6db34868592 style efaa63f2_66e7_f8de_f995_2d111f40adb6 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/standard-tests/langchain_tests/integration_tests/sandboxes.py lines 198–214
def test_upload_download_roundtrip(
self, sandbox_backend: SandboxBackendProtocol
) -> None:
"""Upload then download and verify bytes survive a roundtrip."""
if not self.has_sync:
pytest.skip("Sync tests not supported.")
test_path = "/tmp/test_roundtrip.txt"
test_content = b"Roundtrip test: special chars \n\t\r\x00"
upload_responses = sandbox_backend.upload_files([(test_path, test_content)])
assert upload_responses == [FileUploadResponse(path=test_path, error=None)]
download_responses = sandbox_backend.download_files([test_path])
assert download_responses == [
FileDownloadResponse(path=test_path, content=test_content, error=None)
]
Domain
Subdomains
Source
Frequently Asked Questions
What does test_upload_download_roundtrip() do?
test_upload_download_roundtrip() is a function in the langchain codebase, defined in libs/standard-tests/langchain_tests/integration_tests/sandboxes.py.
Where is test_upload_download_roundtrip() defined?
test_upload_download_roundtrip() is defined in libs/standard-tests/langchain_tests/integration_tests/sandboxes.py at line 198.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free