summaryrefslogtreecommitdiff
path: root/src/beautifulsoup/tests/test_html5lib.py
diff options
context:
space:
mode:
authorLeonard Richardson <leonard.richardson@canonical.com>2011-01-03 21:36:13 -0500
committerLeonard Richardson <leonard.richardson@canonical.com>2011-01-03 21:36:13 -0500
commit692fe5201d5dec15a3598578a6f403e67802de0d (patch)
tree7ab5c761163b5fae77304ff8b6769afd8a9d84e1 /src/beautifulsoup/tests/test_html5lib.py
parentea57d5122f1df133927e266e5fabbf0ef767f460 (diff)
Brought in a treebuilder from html5lib and got it to work.
Diffstat (limited to 'src/beautifulsoup/tests/test_html5lib.py')
-rw-r--r--src/beautifulsoup/tests/test_html5lib.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/beautifulsoup/tests/test_html5lib.py b/src/beautifulsoup/tests/test_html5lib.py
index 7164dac..131c999 100644
--- a/src/beautifulsoup/tests/test_html5lib.py
+++ b/src/beautifulsoup/tests/test_html5lib.py
@@ -11,6 +11,11 @@ class TestHTML5Builder(BuilderSmokeTest):
def setUp(self):
self.default_builder = HTML5TreeBuilder()
+ def test_collapsed_whitespace(self):
+ """Whitespace is preserved even in tags that don't require it."""
+ self.assertSoupEquals("<p> </p>")
+ self.assertSoupEquals("<b> </b>")
+
class TestHTML5BuilderInvalidMarkup(BuilderInvalidMarkupSmokeTest):
"""See `BuilderInvalidMarkupSmokeTest`."""