1、补充提交

This commit is contained in:
dark 2026-06-02 16:58:23 +08:00
parent 6dfb79dcd2
commit 6e694224ef

View File

@ -144,20 +144,3 @@ def test_prompt_history_creates_runtime_dir(tmp_path: Path, monkeypatch):
assert callable(prompt)
assert (tmp_path / "runtime").is_dir()
def test_packaged_chat_uses_plain_input_by_default(monkeypatch):
monkeypatch.setattr("sys.frozen", True, raising=False)
monkeypatch.delenv("PAM_CHAT_PROMPT_TOOLKIT", raising=False)
monkeypatch.delenv("PAM_CHAT_SIMPLE_INPUT", raising=False)
prompt = _build_prompt_input(builtins.input)
assert prompt is builtins.input
def test_simple_input_env_disables_prompt_toolkit(monkeypatch):
monkeypatch.setenv("PAM_CHAT_SIMPLE_INPUT", "1")
prompt = _build_prompt_input(builtins.input)
assert prompt is builtins.input