refactor: remove use of eval for node validation (#944)

This commit is contained in:
Juro Oravec 2025-02-02 10:35:39 +01:00 committed by GitHub
parent de32d449d9
commit f52f12579b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 216 additions and 101 deletions

View file

@ -737,7 +737,7 @@ class SpreadOperatorTests(BaseTestCase):
template1 = Template(template_str1)
with self.assertRaisesMessage(SyntaxError, "keyword argument repeated"):
with self.assertRaisesMessage(TypeError, "got multiple values for argument 'x'"):
template1.render(context)
# But, similarly to python, we can merge multiple **kwargs by instead