diff options
Diffstat (limited to 'tests/test_builder_registry.py')
-rw-r--r-- | tests/test_builder_registry.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/tests/test_builder_registry.py b/tests/test_builder_registry.py index ee5b2da..655cd06 100644 --- a/tests/test_builder_registry.py +++ b/tests/test_builder_registry.py @@ -8,7 +8,8 @@ from bs4.builder import ( LXMLTreeBuilderForXML, LXMLTreeBuilder, TreeBuilderRegistry, - HTML5TreeBuilder + HTML5TreeBuilder, + HTMLParserTreeBuilder, ) @@ -21,6 +22,8 @@ class BuiltInRegistryTest(unittest.TestCase): LXMLTreeBuilder) self.assertEquals(registry.lookup('permissive', 'xml'), LXMLTreeBuilderForXML) + self.assertEquals(registry.lookup('strict', 'html'), + HTMLParserTreeBuilder) self.assertEquals(registry.lookup('permissive', 'html'), HTML5TreeBuilder) @@ -36,6 +39,9 @@ class BuiltInRegistryTest(unittest.TestCase): self.assertEquals(registry.lookup('html5lib'), HTML5TreeBuilder) + self.assertEquals(registry.lookup('html.parser'), + HTMLParserTreeBuilder) + def test_unimplemented_combinations(self): self.assertEquals(registry.lookup('fast', 'permissive', 'html'), None) |