summaryrefslogtreecommitdiff
path: root/tests/test_lxml.py
diff options
context:
space:
mode:
authorLeonard Richardson <leonard.richardson@canonical.com>2011-02-13 19:59:44 -0500
committerLeonard Richardson <leonard.richardson@canonical.com>2011-02-13 19:59:44 -0500
commitbc97bb3a83ee9fb4c8e31d11069ccf1cda61d4ff (patch)
treebf0637e79bc667a1b5ae08ca4794df414f169992 /tests/test_lxml.py
parenta011baa0e95e3d42d647cdf68164ba1c30314492 (diff)
Added tests of nonsensical declarations.
Diffstat (limited to 'tests/test_lxml.py')
-rw-r--r--tests/test_lxml.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/test_lxml.py b/tests/test_lxml.py
index 028b956..cba5522 100644
--- a/tests/test_lxml.py
+++ b/tests/test_lxml.py
@@ -298,8 +298,9 @@ class TestLXMLBuilderInvalidMarkup(SoupTest):
markup = "<p>one<!DOCTYPE foobar>two</p>"
self.assertSoupEquals(markup)
- #def testJunkInDeclaration(self):
- # self.assertSoupEquals('<! Foo = -8>a', '<!Foo = -8>a')
+ def test_nonsensical_declaration(self):
+ # Declarations that don't make any sense are ignored.
+ self.assertSoupEquals('<! Foo = -8><p>a</p>', "<p>a</p>")
def test_cdata_where_it_doesnt_belong(self):
#CDATA sections are ignored.