mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-08-15 14:08:00 +00:00
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:
parent
0eff77c73d
commit
32e8e4045a
1 changed files with 1 additions and 4 deletions
|
@ -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())
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue