aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorDanilo M. <danix@danix.xyz>2026-11-10 18:16:32 +0100
committerDanilo M. <danix@danix.xyz>2026-11-10 18:16:32 +0100
commitb22003b6a86f16f3de6f77093fb94d8b89203dc2 (patch)
tree4ebd032f6c92751d2749f6a7bc78d1f3c1ab23e8 /tests
parent9f6f909d696c2f8b1e1e8261431e3d815baf277e (diff)
downloaddeck-it-b22003b6a86f16f3de6f77093fb94d8b89203dc2.tar.gz
deck-it-b22003b6a86f16f3de6f77093fb94d8b89203dc2.zip
feat(llm): desktop-assistant usage as Local Agent
The LLM usage card gets a third section, the desktop-assistant program from llm-cost-dashboard, with the same session and total stats as opencode. The per-program aggregation now takes the program. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/test_llm.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/test_llm.py b/tests/test_llm.py
index 48e49fe..3820249 100644
--- a/tests/test_llm.py
+++ b/tests/test_llm.py
@@ -33,7 +33,7 @@ class Down(unittest.TestCase):
class Up(unittest.TestCase):
- def test_aggregates_opencode_and_ignores_other_programs(self):
+ def test_aggregates_opencode_and_assistant_apart(self):
data = {"/api/claude_limits": [{"context_pct": 12}],
"/api/claude_session": {"session": {"models": [{"model": "claude-opus-4"}]}},
"/api/summary": [
@@ -64,6 +64,9 @@ class Up(unittest.TestCase):
self.assertEqual(st["opencode"]["session_cost"], 0.5)
self.assertEqual(st["opencode"]["session_calls"], 4)
self.assertEqual(st["opencode"]["session_tokens"], 500)
+ self.assertEqual(st["assistant"]["cost"], 9.0)
+ self.assertEqual(st["assistant"]["calls"], 9)
+ self.assertIsNone(st["assistant"]["model"])
def test_handles_the_real_latest_shape(self):
data = {"/api/claude_limits": {"latest": {"context_pct": 42, "five_hour_pct": 10}},