def test_isEqualToNode(self):
        """
        L{Element.isEqualToNode} returns C{True} if and only if passed a
        L{Element} with the same C{nodeName}, C{namespace}, C{childNodes}, and
        C{attributes}.
        """
        self.assertTrue(
            microdom.Element(
                'foo', {'a': 'b'}, object(), namespace='bar').isEqualToNode(
                microdom.Element(
                    'foo', {'a': 'b'}, object(), namespace='bar')))

        # Elements with different nodeName values do not compare equal.
        self.assertFalse(
            microdom.Element(
                'foo', {'a': 'b'}, object(), namespace='bar').isEqualToNode(
                microdom.Element(
                    'bar', {'a': 'b'}, object(), namespace='bar')))

        # Elements with different namespaces do not compare equal.
        self.assertFalse(
            microdom.Element(
                'foo', {'a': 'b'}, object(), namespace='bar').isEqualToNode(
                microdom.Element(
                    'foo', {'a': 'b'}, object(), namespace='baz')))

        # Elements with different childNodes do not compare equal.
        one = microdom.Element('foo', {'a': 'b'}, object(), namespace='bar')
        two = microdom.Element('foo', {'a': 'b'}, object(), namespace='bar')
        two.appendChild(microdom.Node(object()))
        self.assertFalse(one.isEqualToNode(two))

        # Elements with different attributes do not compare equal.
        self.assertFalse(
            microdom.Element(
                'foo', {'a': 'b'}, object(), namespace='bar').isEqualToNode(
                microdom.Element(
                    'foo', {'a': 'c'}, object(), namespace='bar')))

        L{Element.isEqualToNode} returns C{True} if and only if passed a
        L{Element} with the same C{nodeName}, C{namespace}, C{childNodes}, and
        C{attributes}.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/web/test/test_xml.py