"""Wake-word defaults and normalization tests."""

from __future__ import annotations

from app.services.voice_service import DEFAULT_WAKE_WORD, strip_wake_word
from voice_client import DEFAULT_WAKE_ALIASES


def test_default_wake_word_is_orion() -> None:
    """Voice defaults should arm on Orion."""
    assert DEFAULT_WAKE_WORD == "Orion"
    assert any("orion" in alias.lower() for alias in DEFAULT_WAKE_ALIASES)


def test_strip_wake_word_handles_case_and_aliases() -> None:
    """Wake detection should be case-insensitive for Orion and aliases."""
    assert strip_wake_word("Orion what tasks do I have", wake_aliases=list(DEFAULT_WAKE_ALIASES)) == "what tasks do i have"
    assert strip_wake_word("orion", wake_aliases=list(DEFAULT_WAKE_ALIASES)) == ""
    assert strip_wake_word("OK ORION run diagnostics", wake_aliases=list(DEFAULT_WAKE_ALIASES)) == "run diagnostics"
