Make sure telemetry arguments are not returned as unused kwargs (#17063)

* Make sure telemetry arguments are not returned as unused kwargs

* Fix test
This commit is contained in:
Sylvain Gugger
2022-05-04 07:47:57 -04:00
committed by GitHub
parent 675e2d1663
commit d76d2a2af7
2 changed files with 5 additions and 1 deletions

View File

@@ -356,7 +356,7 @@ class ConfigurationVersioningTest(unittest.TestCase):
)
self.assertEqual(new_configuration.hidden_size, 2)
# This checks `_configuration_file` ia not kept in the kwargs by mistake.
self.assertDictEqual(kwargs, {"_from_auto": True})
self.assertDictEqual(kwargs, {})
# Testing an older version by monkey-patching the version in the module it's used.
import transformers as old_transformers