test_standard.py — langchain Source File
Architecture documentation for test_standard.py, a python file in the langchain codebase. 6 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR 623fccd8_6ba8_47ee_6e63_8982e5b414b8["test_standard.py"] 2bf6d401_816d_d011_3b05_a6114f55ff58["collections.abc"] 623fccd8_6ba8_47ee_6e63_8982e5b414b8 --> 2bf6d401_816d_d011_3b05_a6114f55ff58 f69d6389_263d_68a4_7fbf_f14c0602a9ba["pytest"] 623fccd8_6ba8_47ee_6e63_8982e5b414b8 --> f69d6389_263d_68a4_7fbf_f14c0602a9ba f75e66a0_314a_f961_16d7_464ee959064b["langchain_core.vectorstores"] 623fccd8_6ba8_47ee_6e63_8982e5b414b8 --> f75e66a0_314a_f961_16d7_464ee959064b 0f7c8fad_78b2_07eb_8d9d_ced3ed7b4704["langchain_tests.integration_tests.vectorstores"] 623fccd8_6ba8_47ee_6e63_8982e5b414b8 --> 0f7c8fad_78b2_07eb_8d9d_ced3ed7b4704 4e10449f_1140_2e1d_c00d_fe1b4f649212["pytest_benchmark.fixture"] 623fccd8_6ba8_47ee_6e63_8982e5b414b8 --> 4e10449f_1140_2e1d_c00d_fe1b4f649212 58dfd1cb_b261_b21f_643f_de389346ebe9["langchain_chroma"] 623fccd8_6ba8_47ee_6e63_8982e5b414b8 --> 58dfd1cb_b261_b21f_643f_de389346ebe9 style 623fccd8_6ba8_47ee_6e63_8982e5b414b8 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
from collections.abc import Generator
import pytest
from langchain_core.vectorstores import VectorStore
from langchain_tests.integration_tests.vectorstores import VectorStoreIntegrationTests
from pytest_benchmark.fixture import BenchmarkFixture # type: ignore[import-untyped]
from langchain_chroma import Chroma
class TestChromaStandard(VectorStoreIntegrationTests):
@pytest.fixture
def vectorstore(self) -> Generator[VectorStore, None, None]: # type: ignore[override]
"""Get an empty vectorstore for unit tests."""
store = Chroma(embedding_function=self.get_embeddings())
try:
yield store
finally:
store.delete_collection()
@pytest.mark.benchmark
def test_chroma_init_time(benchmark: BenchmarkFixture) -> None:
"""Test Chroma initialization time."""
def _init_chroma() -> None:
for _ in range(10):
Chroma()
benchmark(_init_chroma)
Domain
Subdomains
Functions
Classes
Dependencies
- collections.abc
- langchain_chroma
- langchain_core.vectorstores
- langchain_tests.integration_tests.vectorstores
- pytest
- pytest_benchmark.fixture
Source
Frequently Asked Questions
What does test_standard.py do?
test_standard.py is a source file in the langchain codebase, written in python. It belongs to the LangChainCore domain, Runnables subdomain.
What functions are defined in test_standard.py?
test_standard.py defines 1 function(s): test_chroma_init_time.
What does test_standard.py depend on?
test_standard.py imports 6 module(s): collections.abc, langchain_chroma, langchain_core.vectorstores, langchain_tests.integration_tests.vectorstores, pytest, pytest_benchmark.fixture.
Where is test_standard.py in the architecture?
test_standard.py is located at libs/partners/chroma/tests/unit_tests/test_standard.py (domain: LangChainCore, subdomain: Runnables, directory: libs/partners/chroma/tests/unit_tests).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free