diff options
author | Leonard Richardson <leonard.richardson@canonical.com> | 2011-02-13 10:37:24 -0500 |
---|---|---|
committer | Leonard Richardson <leonard.richardson@canonical.com> | 2011-02-13 10:37:24 -0500 |
commit | 84d7f8dd319039d385b9afe1da751006be2c9859 (patch) | |
tree | b265fc282c99140d1371962b2339bc32cde1beff /tests/test_lxml.py | |
parent | d89c8878ea86a2575c87e9fad8081cfcd81e0bcd (diff) |
Figured out the deal with CDATA sections in lxml and html5lib, and added comments and tests.
Diffstat (limited to 'tests/test_lxml.py')
-rw-r--r-- | tests/test_lxml.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/test_lxml.py b/tests/test_lxml.py index 9a65f6a..207d141 100644 --- a/tests/test_lxml.py +++ b/tests/test_lxml.py @@ -273,3 +273,7 @@ class TestLXMLBuilderInvalidMarkup(SoupTest): markup = "<p>one<!DOCTYPE foobar>two</p>" self.assertSoupEquals(markup) + def test_cdata_where_it_doesnt_belong(self): + #CDATA sections are ignored. + markup = "<div><![CDATA[foo]]>" + self.assertSoupEquals(markup, "<div></div>") |