| 266 | self.assertEqual(["css"], soup.div.div['class']) |
| 267 | |
| 268 | def test_multivalued_attribute_on_html(self): |
| 269 | # html5lib uses a different API to set the attributes ot the |
| 270 | # <html> tag. This has caused problems with multivalued |
| 271 | # attributes. |
| 272 | markup = '<html class="a b"></html>' |
| 273 | soup = self.soup(markup) |
| 274 | self.assertEqual(["a", "b"], soup.html['class']) |
| 275 | |
| 276 | def test_angle_brackets_in_attribute_values_are_escaped(self): |
| 277 | self.assertSoupEquals('<a b="<a>"></a>', '<a b="<a>"></a>') |