MCPcopy
hub / github.com/csev/py4e / test_correctly_nested_tables

Method test_correctly_nested_tables

code3/bs4/testing.py:240–258  ·  view source on GitHub ↗

One table can go inside another one.

(self)

Source from the content-addressed store, hash-verified

238 self.assertEqual(blockquote.b.string, 'Foo')
239
240 def test_correctly_nested_tables(self):
241 """One table can go inside another one."""
242 markup = ('<table id="1">'
243 '<tr>'
244 "<td>Here's another table:"
245 '<table id="2">'
246 '<tr><td>foo</td></tr>'
247 '</table></td>')
248
249 self.assertSoupEquals(
250 markup,
251 '<table id="1"><tr><td>Here\'s another table:&#x27;
252 '<table id="2"><tr><td>foo</td></tr></table>'
253 '</td></tr></table>')
254
255 self.assertSoupEquals(
256 "<table><thead><tr><td>Foo</td></tr></thead>"
257 "<tbody><tr><td>Bar</td></tr></tbody>"
258 "<tfoot><tr><td>Baz</td></tr></tfoot></table>")
259
260 def test_deeply_nested_multivalued_attribute(self):
261 # html5lib can set the attributes of the same tag many times

Callers

nothing calls this directly

Calls 1

assertSoupEqualsMethod · 0.45

Tested by

no test coverage detected