### Question:
AbstractModuleDescriptor implements ModuleDescriptor<T>, StateAware { Class<?> getModuleReturnClass() { try { return getClass().getMethod("getModule").getReturnType(); } catch (NoSuchMethodException e) { throw new IllegalStateException("The getModule() method is missing (!) on " + getClass()); } } AbstractModuleDescriptor(final ModuleFactory moduleFactory); @Deprecated  AbstractModuleDescriptor(); void init(@NotNull final Plugin plugin, @NotNull final Element element); void destroy(final Plugin plugin); boolean isEnabledByDefault(); boolean isSystemModule(); @Deprecated boolean isSingleton(); String getCompleteKey(); String getPluginKey(); String getKey(); String getName(); Class<T> getModuleClass(); abstract T getModule(); String getDescription(); Map<String, String> getParams(); String getI18nNameKey(); String getDescriptionKey(); List<ResourceDescriptor> getResourceDescriptors(); List<ResourceDescriptor> getResourceDescriptors(final String type); ResourceLocation getResourceLocation(final String type, final String name); ResourceDescriptor getResourceDescriptor(final String type, final String name); Float getMinJavaVersion(); boolean satisfiesMinJavaVersion(); void setPlugin(final Plugin plugin); Plugin getPlugin(); @Override String toString(); void enabled(); void disabled();  }### Answer:
@Test public void testGetModuleReturnClass() { AbstractModuleDescriptor desc = new MockAnimalModuleDescriptor(); assertEquals(MockAnimal.class, desc.getModuleReturnClass()); }
@Test public void testGetModuleReturnClassWithExtendsNumber() { ModuleFactory moduleFactory = mock(ModuleFactory.class); AbstractModuleDescriptor moduleDescriptor = new ExtendsNothingModuleDescriptor(moduleFactory, "foo"); assertEquals(Object.class, moduleDescriptor.getModuleReturnClass()); }