node_less

        Low-level api: Return True if all descendants of node1 exist in node2.
        Otherwise False. This is a recursive method.

        Parameters
        ----------

        node1 : `Element`
            A node in a model tree.

        node2 : `Element`
            A node in another model tree.

        Returns
        -------

        bool
            True if all descendants of node1 exist in node2, otherwise False.

def node_less(node1, node2):
        '''node_less

        Low-level api: Return True if all descendants of node1 exist in node2.
        Otherwise False. This is a recursive method.

        Parameters
        ----------

        node1 : `Element`
            A node in a model tree.

        node2 : `Element`
            A node in another model tree.

        Returns
        -------

        bool
            True if all descendants of node1 exist in node2, otherwise False.
        '''

        for x in ['tag', 'text', 'tail']:
            if node1.__getattribute__(x) != node2.__getattribute__(x):
                return False
        for a in node1.attrib:
            if a not in node2.attrib or \
               node1.attrib[a] != node2.attrib[a]:
                return False
        for child in node1.getchildren():
            peers = node2.findall(child.tag)
            if len(peers) < 1:
                return False
            elif len(peers) > 1:
                raise ModelError("not unique peer '{}'".format(child.tag))
            else:
                if not ModelDiff.node_less(child, peers[0]):
                    return False
        return True