### Question:
JavaMailJMSStatistics extends NotificationBroadcasterSupport implements JavaMailJMSStatisticsLocal, DynamicMBean { @Override public MBeanInfo getMBeanInfo() { return M_BEAN_INFO; }  @PostConstruct void registerInJMX(); @PreDestroy void unregisterFromJMX(); void onSuccess(MimeMessage mimeMessage, Address[] addresses); void onFailure(MimeMessage mimeMessage, Address[] addresses, Exception ex); @Override AttributeList getAttributes(String[] attributeNames); @Override Object getAttribute(String attribute); @Override void setAttribute(Attribute attribute); @Override AttributeList setAttributes(AttributeList attributes); @Override Object invoke(String actionName, Object[] params, String[] signature); @Override MBeanInfo getMBeanInfo(); static final String NOTIFICATION_TYPE_SUCCESS; static final String JAVA_MAIL_SEND_FAILURE; static final ObjectName JMX_OBJECT_NAME; }### Answer:
@Test public void testJmxMBeanInfo() throws Exception { MBeanServer platformMBeanServer = ManagementFactory.getPlatformMBeanServer(); MBeanInfo mBeanInfo = platformMBeanServer.getMBeanInfo(JavaMailJMSStatistics.JMX_OBJECT_NAME); assertNotNull(mBeanInfo); }