### Question:
Xsd2UmlPluginDefault implements Xsd2UmlHostedPlugin { @Override public final String nameFromComplexTypeExtension(final QName complexType, final QName base) { if (complexType == null) { throw new IllegalArgumentException("complexType"); } if (base == null) { throw new IllegalArgumentException("base"); } return nameFromSchemaTypeName(complexType).concat(" extends ").concat(nameFromSchemaTypeName(base)); }  @Override final String nameFromComplexTypeExtension(final QName complexType, final QName base); @Override String nameFromSchemaAttributeName(final QName name); @Override String nameFromSchemaElementName(final QName name); @Override String nameFromSchemaTypeName(final QName name); @Override final String nameFromSimpleTypeRestriction(final QName simpleType, final QName base);  }### Answer:
@Test public void testNameFromComplexTypeExtension() throws Exception { String extension = defaultPlugin.nameFromComplexTypeExtension(complexType, name); Assert.assertEquals("complexType extends name", extension); }
@Test(expected = IllegalArgumentException.class) public void testValidateComplexType() throws Exception { defaultPlugin.nameFromComplexTypeExtension(null, name); }
@Test(expected = IllegalArgumentException.class) public void testValidateBaseType() throws Exception { defaultPlugin.nameFromComplexTypeExtension(name, null); }