def METHOD_NAME(self):
    one = ClassFactory.create(
        qname="foo",
        tag=Tag.ELEMENT,
        namespace="a",
        help="b",
        substitutions=["a", "b"],
    )
    two = ClassFactory.create(qname="foo", tag=Tag.COMPLEX_TYPE, substitutions=[])
    three = ClassFactory.create(qname="foo", tag=Tag.SIMPLE_TYPE)
    classes = [one, two, three]
    self.validator.merge_global_types(classes)
    self.assertEqual(3, len(classes))
    classes = [one, three]
    self.validator.merge_global_types(classes)
    self.assertEqual(2, len(classes))
    classes = [two, three]
    self.validator.merge_global_types(classes)
    self.assertEqual(2, len(classes))
    classes = [one, two, three]
    one.attrs.append(AttrFactory.create)
    one.extensions.append(ExtensionFactory.reference(two.qname))
    self.validator.merge_global_types(classes)
    self.assertEqual(3, len(classes))
    one.attrs.clear()
    one.extensions.append(ExtensionFactory.reference("foo"))
    self.validator.merge_global_types(classes)
    self.assertEqual(3, len(classes))
    one.extensions.pop()
    self.validator.merge_global_types(classes)
    self.assertEqual(2, len(classes))
    self.assertIn(two, classes)
    self.assertIn(three, classes)
    self.assertEqual(one.namespace, two.namespace)
    self.assertEqual(one.help, two.help)
    self.assertEqual(one.substitutions, two.substitutions)
    self.assertEqual(2, len(one.substitutions))