Luke Plant  committed 6526d67

Re-enabled test for confusing section structure

  • Participants
  • Parent commits d4e5e90

Comments (0)

Files changed (1)

File semanticeditor/utils/

     # raise BadStructure later, but divs have no semantics so can just
     # be removed.
+    _assert_sane_sections(root, structure)
     section_nodes = {}
     headers = [(level,name,tag,h) for (level,name,tag,h) in structure
     # First, all h1, h2 etc tags will be children of the root.
     # remove_tag should have ensured that, otherwise we will be unable
     # to cut the HTML into sections.
-    for level, name, tag, h in structure:
-        parent = get_parent(root, h)
+    for level, name, tag, node in structure:
+        parent = get_parent(root, node)
         if tag.lower() in headingdef and parent is not root:
             raise BadStructure("Section heading \"%(name)s\" is not at the top level of "
                                "the document. This interferes with the ability to "