feat(Q4): kiosk ambient mode with camera rotation, alert takeover, dimming
Add GET /kiosk/ambient route and standalone fullscreen template with rotating camera snapshots (crossfade), top bar clock/date, pet status bottom bar, SSE-driven alert takeover with HLS playback, configurable screen dimming, and 6-hour auto-refresh. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
29
tests/unit/test_kiosk_ambient.py
Normal file
29
tests/unit/test_kiosk_ambient.py
Normal file
@@ -0,0 +1,29 @@
|
||||
import pytest
|
||||
from vigilar.config import VigilarConfig
|
||||
from vigilar.web.app import create_app
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def kiosk_app():
|
||||
cfg = VigilarConfig()
|
||||
app = create_app(cfg)
|
||||
app.config["TESTING"] = True
|
||||
return app
|
||||
|
||||
|
||||
def test_ambient_route_exists(kiosk_app):
|
||||
with kiosk_app.test_client() as c:
|
||||
rv = c.get("/kiosk/ambient")
|
||||
assert rv.status_code == 200
|
||||
|
||||
|
||||
def test_ambient_contains_clock(kiosk_app):
|
||||
with kiosk_app.test_client() as c:
|
||||
rv = c.get("/kiosk/ambient")
|
||||
assert b"clock" in rv.data
|
||||
|
||||
|
||||
def test_ambient_contains_hls(kiosk_app):
|
||||
with kiosk_app.test_client() as c:
|
||||
rv = c.get("/kiosk/ambient")
|
||||
assert b"hls.min.js" in rv.data
|
||||
Reference in New Issue
Block a user