From 0b6ace649832e245cb132986e788fee5a12ec6d6 Mon Sep 17 00:00:00 2001 From: Teknium <127238744+teknium1@users.noreply.github.com> Date: Wed, 27 May 2026 03:04:36 -0700 Subject: [PATCH] test(verbose): align with telegram tier-1 inbox default MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Two tests in test_verbose_command.py asserted Telegram's tool_progress default was "new" and expected /verbose to cycle that to "all". The default has since been overridden to "off" in gateway/display_config.py (_PLATFORM_DEFAULTS for telegram — tier-1 inbox preset that keeps mobile chats final-answer-first), making the first /verbose invocation cycle off → new, not all → verbose. The behavioral change was intentional; the tests were stale and missing from the same commit. Surfaced as a pre-existing failure on origin/main during CI for the unrelated #33164 / #33168 Codex auth salvages. --- tests/gateway/test_verbose_command.py | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/tests/gateway/test_verbose_command.py b/tests/gateway/test_verbose_command.py index 7b8d0445129..055d61c262f 100644 --- a/tests/gateway/test_verbose_command.py +++ b/tests/gateway/test_verbose_command.py @@ -128,8 +128,14 @@ class TestVerboseCommand: f"Expected {mode}, got {actual}" @pytest.mark.asyncio - async def test_defaults_to_all_when_no_tool_progress_set(self, tmp_path, monkeypatch): - """When tool_progress is not in config, defaults to platform default then cycles.""" + async def test_defaults_to_platform_default_when_no_tool_progress_set(self, tmp_path, monkeypatch): + """When tool_progress is not in config, starts from platform default then cycles. + + Telegram's tier-1 preset overrides ``tool_progress`` to ``"off"`` so the + platform stays final-answer-first by default on mobile inboxes. The + first ``/verbose`` invocation therefore cycles ``off → new``, not + ``all → ...``. + """ hermes_home = tmp_path / "hermes" hermes_home.mkdir() config_path = hermes_home / "config.yaml" @@ -143,17 +149,18 @@ class TestVerboseCommand: runner = _make_runner() result = await runner._handle_verbose_command(_make_event()) - # Telegram platform default is "new" → cycles to "all" - assert "ALL" in result + # Telegram platform default is "off" → cycles to "new" + assert "NEW" in result saved = yaml.safe_load(config_path.read_text(encoding="utf-8")) - assert saved["display"]["platforms"]["telegram"]["tool_progress"] == "all" + assert saved["display"]["platforms"]["telegram"]["tool_progress"] == "new" @pytest.mark.asyncio async def test_per_platform_isolation(self, tmp_path, monkeypatch): """Cycling /verbose on Telegram doesn't change Slack's setting. Without a global tool_progress, each platform uses its built-in - default: Telegram = 'new' (overridden high tier), Slack = 'off' (quiet Slack default). + default — Telegram = 'off' (tier-1 inbox override), Slack = 'off' + (quiet Slack default). Both cycle to 'new' on first /verbose. """ hermes_home = tmp_path / "hermes" hermes_home.mkdir() @@ -178,8 +185,8 @@ class TestVerboseCommand: saved = yaml.safe_load(config_path.read_text(encoding="utf-8")) platforms = saved["display"]["platforms"] - # Telegram: new -> all (platform default = new) - assert platforms["telegram"]["tool_progress"] == "all" + # Telegram: off -> new (platform default = off, tier-1 inbox override) + assert platforms["telegram"]["tool_progress"] == "new" # Slack: off -> new (first /verbose cycle from quiet default) assert platforms["slack"]["tool_progress"] == "new"