Each type (sound, image, video) can now have 1 to 8 named players on
/admin, reordered with the arrows; the first opens by default. A tap opens
with it, a long press (or right click) on a file lists the others. The
open_media message takes an optional opener id; the client can only name a
player already configured for the file's type, and the command is still
rebuilt from the database. Tablets receive player names and kinds (never
the spec) and are notified on every change.
media_openers (one row per type) becomes media_players; existing settings
are migrated as unnamed players whose id is the type, so the old
PUT /api/media/openers/<type> keeps working. A type always keeps a player.
With real touch events the click following a long press landed on the
chooser backdrop (closing it at once) or on one of its buttons (opening a
player by mistake); clicks of the opening gesture are now ignored.
Tests: store, migration, REST, WebSocket choice and refusals, and a
Chromium test with touch long press, release click, Escape and right click.
The UI tests no longer leave /admin before the token is stored.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Move the private D-Bus bus, isolated XDG dirs and PATH, fake gio/pactl/
firefox/launcher programs and the real MediaDeckServer into tests/stack.py,
and make test_integration.py use it.
The test bus is started from a configuration without any service
directory, so nothing from the system (portals, kwallet, kdeconnect...) can
ever be activated on it.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Real MediaDeckServer under aiohttp.test_utils, private session bus,
isolated XDG dirs and PATH, fake MPRIS player and fake gio/pactl/launcher
programs that log their arguments. Covers authentication, player listing
and control, audio, media listing and path escapes, shell-free opening of
a hostile file name, imported launchers and admin changes pushed to
clients. Verified to fail when the hidden-component check, the token check
or the metadata enrichment is removed.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>