From 9139655e544e60b59c31ad23cd3bb66f572971ef Mon Sep 17 00:00:00 2001 From: worldmozara Date: Mon, 26 Oct 2026 00:52:58 +0800 Subject: [PATCH] test: cover the limit prompt line while a notification offers buttons The answer now comes from the notification hook, and the terminal still has to spell out the keys it accepts. --- tests/test_cli/test_limits.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tests/test_cli/test_limits.py b/tests/test_cli/test_limits.py index ac9c9dd..b10ab56 100644 --- a/tests/test_cli/test_limits.py +++ b/tests/test_cli/test_limits.py @@ -396,6 +396,15 @@ def test_a_limit_prompt_can_stop_the_turn_from_the_notification() -> None: assert limits.prompt_continue_limit("hit a wall") is False +def test_a_limit_prompt_still_names_its_answers_at_the_terminal(capsys: pytest.CaptureFixture[str]) -> None: + """Buttons elsewhere do not say what typing here would do.""" + from plyngent.cli import limits + + with temporary_backend(ScriptedBackend([])), _answered("y"): + assert limits.prompt_continue_limit("hit a wall") is True + assert "[Y/n/yyy]" in capsys.readouterr().err + + def test_a_skill_write_can_be_allowed_for_the_chat_from_the_notification() -> None: """``s`` (this chat) is a button, not only a terminal token.""" from pathlib import Path