def test_html_handling(self):
pu = parse_update(_build_payload("123<hr>,456"), None, "")
self.assertEqual(pu.number, 123)
+
+ pu = parse_update(_build_payload("<pre>123\n456</pre>"), None, "")
+ self.assertEqual(pu.number, 123)
worklist.extend(reversed(el.contents))
worklist.append(NEW_LINE)
elif el.name == "pre":
- worklist.append(NEW_LINE)
- worklist.extend([l for l in reversed(el.text.splitlines())])
- worklist.append(NEW_LINE)
+ out.extend([l] for l in el.text.splitlines())
+ out.append([])
elif el.name == "tr":
worklist.append(NEW_LINE)
for (i, cell) in enumerate(reversed(el.contents)):