fix(tests): remove @pytest.mark.asyncio decorators from unit tests

Pre-commit hook forbids @pytest.mark.asyncio since pytest is configured
with async-mode=auto. Removed the decorators from embedding precedence tests.
This commit is contained in:
skamenan7 2025-07-28 09:32:24 -04:00 committed by Sumanth Kamenani
parent 0eff77c73d
commit 32e8e4045a

View file

@ -40,7 +40,6 @@ class _DummyRoutingTable:
raise NotImplementedError raise NotImplementedError
@pytest.mark.asyncio
async def test_global_default_used(monkeypatch): async def test_global_default_used(monkeypatch):
"""Router should pick up global default when no explicit model is supplied.""" """Router should pick up global default when no explicit model is supplied."""
@ -58,7 +57,6 @@ async def test_global_default_used(monkeypatch):
monkeypatch.delenv("LLAMA_STACK_DEFAULT_EMBEDDING_DIMENSION", raising=False) monkeypatch.delenv("LLAMA_STACK_DEFAULT_EMBEDDING_DIMENSION", raising=False)
@pytest.mark.asyncio
async def test_explicit_override(monkeypatch): async def test_explicit_override(monkeypatch):
"""Explicit model parameter should override global default.""" """Explicit model parameter should override global default."""
@ -73,8 +71,7 @@ async def test_explicit_override(monkeypatch):
monkeypatch.delenv("LLAMA_STACK_DEFAULT_EMBEDDING_MODEL", raising=False) monkeypatch.delenv("LLAMA_STACK_DEFAULT_EMBEDDING_MODEL", raising=False)
@pytest.mark.asyncio async def test_error_when_no_default():
async def test_error_when_no_default(monkeypatch):
"""Router should raise when neither explicit nor global default is available.""" """Router should raise when neither explicit nor global default is available."""
router = VectorIORouter(routing_table=_DummyRoutingTable()) router = VectorIORouter(routing_table=_DummyRoutingTable())