mirror of
https://github.com/hwchase17/langchain.git
synced 2026-06-09 18:50:33 +00:00
18 lines
507 B
Python
18 lines
507 B
Python
"""Unit tests for standard tests in Nomic partner integration."""
|
|
|
|
import pytest
|
|
from pytest_benchmark.fixture import BenchmarkFixture # type: ignore[import]
|
|
|
|
from langchain_nomic import NomicEmbeddings
|
|
|
|
|
|
@pytest.mark.benchmark
|
|
def test_nomic_embeddings_init_time(benchmark: BenchmarkFixture) -> None:
|
|
"""Test NomicEmbeddings initialization time."""
|
|
|
|
def _init_nomic_embeddings() -> None:
|
|
for _ in range(10):
|
|
NomicEmbeddings(model="test")
|
|
|
|
benchmark(_init_nomic_embeddings)
|