Commit 143be498 authored by Titouan Soulard's avatar Titouan Soulard

erp5_corporate_identity_test: add test for escape in overridden fields

parent 8a13880e
Pipeline #39369 failed with stage
in 0 seconds
......@@ -497,3 +497,13 @@ class TestCorporateIdentityMethod(ERP5TypeTestCase):
)
self.assertEqual(output, None)
def test_escapeOverridden(self):
book_export = self.portal.web_page_module.template_test_book_input_003_en_html.WebPage_viewAsBook(
format="html",
override_document_description='<script>alert("description");</script>',
override_document_short_title='<script>alert("short title");</script>',
override_document_title='<script>alert("title");</script>',
override_document_version='<script>alert("001");</script>',
override_document_reference='<script>alert("reference");</script>',
)
self.assertNotIn("<script>alert", book_export)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment