human behavior: classifier gate, pacing, splitting, quiet hours, stable prompt prefix
This commit is contained in:
@@ -35,9 +35,10 @@ class TestPerChannelPrompt(unittest.TestCase):
|
||||
|
||||
|
||||
class TestNewsFileMissing(unittest.TestCase):
|
||||
def test_missing_news_file_keeps_placeholder(self):
|
||||
"""CFG-03: nonexistent news file -> {news} placeholder stays literal, no crash."""
|
||||
def test_missing_news_file_degrades_silently(self):
|
||||
"""CFG-03 (revised): nonexistent news file -> no news section, no literal, no crash."""
|
||||
config = {"system": "N: {news}", "history-limit": 5, "news": "/nonexistent/news.txt"}
|
||||
responder = AIResponder(config, "chat")
|
||||
system = responder.message(AIMessage("alice", "hei"))[0]["content"]
|
||||
self.assertIn("{news}", system)
|
||||
self.assertNotIn("{news}", system)
|
||||
self.assertNotIn("news:", system)
|
||||
|
||||
Reference in New Issue
Block a user