From 9ec094c65b745cde96e64b77231f87f0fd33f4ab Mon Sep 17 00:00:00 2001
From: Nicolas Delaby <nicolas@nexedi.com>
Date: Fri, 5 Mar 2010 16:36:52 +0000
Subject: [PATCH] Test comment stripping. This test is known to fails because
 comment nodes inside style element are escaped (become CDATA).

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@33469 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 product/ERP5OOo/tests/testDms.py | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/product/ERP5OOo/tests/testDms.py b/product/ERP5OOo/tests/testDms.py
index 6e51493e7c..7069e18d8a 100644
--- a/product/ERP5OOo/tests/testDms.py
+++ b/product/ERP5OOo/tests/testDms.py
@@ -1472,7 +1472,10 @@ le3\\\">ERP5:<br />=0A   </p>=0A  <p class=3D\\\"style3\\\"><strong>ERP5</strong
 <br />=0A    ERP5</p>=0A</di=
 v>=0A</body>=0A</html>=0A
 <br>=
-
+<!-- This is a comment, This string AZERTYY shouldn't be dislayed-->
+<style>
+<!-- This is a comment, This string AZERTYY shouldn't be dislayed-->
+</style>
 <table class=3DMoNormalTable border=3D0 cellspacing=3D0 cellpadding=3D0 =
 width=3D64
  style=3D'width:48.0pt;margin-left:-.75pt;border-collapse:collapse'>
@@ -1490,6 +1493,7 @@ style=3D'color:black'>05D65812<o:p></o:p></span></p>
     web_page.edit(text_content=html_content)
     safe_html = web_page.asSafeHTML()
     self.assertTrue('inside very broken HTML code' in html_content)
+    self.assertTrue('AZERTYY' not in html_content)
 
 class TestDocumentWithSecurity(ERP5TypeTestCase):
 
-- 
2.30.9