mirror of
https://github.com/jmagar/unraid-mcp.git
synced 2026-03-23 12:39:24 -07:00
refactor(subscriptions): extract SNAPSHOT_ACTIONS/COLLECT_ACTIONS to subscriptions/queries.py
Moves the subscription query dicts out of tools/live.py into a new subscriptions/queries.py module so subscriptions/resources.py can import them without creating a cross-layer subscriptions→tools dependency.
This commit is contained in:
@@ -116,3 +116,10 @@ async def test_subscribe_collect_returns_multiple_events(mock_ws):
|
||||
|
||||
assert len(result) == 2
|
||||
assert result[0]["notificationAdded"]["id"] == "1"
|
||||
|
||||
|
||||
def test_snapshot_actions_importable_from_subscriptions() -> None:
|
||||
from unraid_mcp.subscriptions.queries import COLLECT_ACTIONS, SNAPSHOT_ACTIONS
|
||||
|
||||
assert "cpu" in SNAPSHOT_ACTIONS
|
||||
assert "log_tail" in COLLECT_ACTIONS
|
||||
|
||||
Reference in New Issue
Block a user