fix(tests): update monkeypatch path for evaluate_response

The import was moved to module top in nanobot/cli/commands.py,
so tests must patch nanobot.cli.commands.evaluate_response instead
of nanobot.utils.evaluator.evaluate_response.
This commit is contained in:
chengyongru 2026-05-27 23:23:58 +08:00 committed by Xubin Ren
parent fe2af64e04
commit 1a4ae8994d

View File

@ -1210,7 +1210,7 @@ def test_gateway_cron_evaluator_receives_scheduled_reminder_context(
monkeypatch.setattr("nanobot.cli.commands.AgentLoop", _FakeAgentLoop)
monkeypatch.setattr("nanobot.channels.manager.ChannelManager", _StopAfterCronSetup)
monkeypatch.setattr(
"nanobot.utils.evaluator.evaluate_response",
"nanobot.cli.commands.evaluate_response",
_capture_evaluate_response,
)
@ -1342,7 +1342,7 @@ def test_gateway_cron_job_suppresses_intermediate_progress(
monkeypatch.setattr("nanobot.cli.commands.AgentLoop", _FakeAgentLoop)
monkeypatch.setattr("nanobot.channels.manager.ChannelManager", _StopAfterCronSetup)
monkeypatch.setattr(
"nanobot.utils.evaluator.evaluate_response",
"nanobot.cli.commands.evaluate_response",
_always_reject,
)