Fixing tests. It seems master changed something in the warnings. (#9483)
Trying to keep warning tests for now. Should be discarded if it becomes too hard to maintain.
This commit is contained in:
parent
1c19b423bf
commit
96f1f74aaf
|
@ -134,10 +134,10 @@ class SimpleConversationPipelineTests(unittest.TestCase):
|
||||||
generated_responses=["b"],
|
generated_responses=["b"],
|
||||||
)
|
)
|
||||||
with self.assertLogs("transformers", level="WARNING") as log:
|
with self.assertLogs("transformers", level="WARNING") as log:
|
||||||
_ = conversation_agent(conversation, max_length=60)
|
_ = conversation_agent(conversation, max_length=64)
|
||||||
self.assertEqual(len(log.output), 3)
|
self.assertEqual(len(log.output), 3)
|
||||||
self.assertIn("Cutting history off because it's too long (63 > 28) for underlying model", log.output[0])
|
self.assertIn("Cutting history off because it's too long (63 > 32) for underlying model", log.output[0])
|
||||||
self.assertIn("63 is bigger than 0.9 * max_length: 60", log.output[1])
|
self.assertIn("63 is bigger than 0.9 * max_length: 64", log.output[1])
|
||||||
self.assertIn("Setting `pad_token_id`", log.output[2])
|
self.assertIn("Setting `pad_token_id`", log.output[2])
|
||||||
self.assertEqual(conversation._index, 1)
|
self.assertEqual(conversation._index, 1)
|
||||||
self.assertEqual(
|
self.assertEqual(
|
||||||
|
|
Loading…
Reference in New Issue