summaryrefslogtreecommitdiff
path: root/tests/test_html5lib.py
diff options
context:
space:
mode:
authorLeonard Richardson <leonard.richardson@canonical.com>2011-02-19 21:21:14 -0500
committerLeonard Richardson <leonard.richardson@canonical.com>2011-02-19 21:21:14 -0500
commit22e7fc268c6150f812e9af55f28dba7aeda4d053 (patch)
tree766662556ae441c5474e754fe9d582ffce3ff257 /tests/test_html5lib.py
parent8249b803d9bab9c06be02a244e629cb732f4f5b1 (diff)
parent9a936b48fe05666780662c76d5df3b3de7b48074 (diff)
Preliminary work for getting XML parsing to work.
Diffstat (limited to 'tests/test_html5lib.py')
-rw-r--r--tests/test_html5lib.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/test_html5lib.py b/tests/test_html5lib.py
index 3045b02..336f9a5 100644
--- a/tests/test_html5lib.py
+++ b/tests/test_html5lib.py
@@ -40,6 +40,12 @@ class TestHTML5Builder(TestLXMLBuilder):
"<tbody><tr><td>Bar</td></tr></tbody>"
"<tfoot><tr><td>Baz</td></tr></tfoot></table>")
+ def test_literal_in_textarea(self):
+ markup = '<textarea>Junk like <b> tags and <&<&amp;</textarea>'
+ soup = self.soup(markup)
+ self.assertEquals(
+ soup.textarea.contents, ["Junk like <b> tags and <&<&"])
+
def test_collapsed_whitespace(self):
"""Whitespace is preserved even in tags that don't require it."""
self.assertSoupEquals("<p> </p>")