ComponentType type = new ComponentType("MBean", "Platform");
ManagedComponent mo = mgtView.getComponent(ManagementFactory.RUNTIME_MXBEAN_NAME, type);
assertNotNull(mo);
assertEquals(ManagementFactory.RUNTIME_MXBEAN_NAME, mo.getName());
RuntimeMXBean mbean = ManagementFactory.getRuntimeMXBean();
MetaValueFactory metaValueFactory = MetaValueFactory.getInstance();
ManagedProperty bootClassPath = mo.getProperty("bootClassPath");
String x = (String) metaValueFactory.unwrap(bootClassPath.getValue());
assertTrue(x.length() > 0);
ManagedProperty classPath = mo.getProperty("classPath");
x = (String) metaValueFactory.unwrap(classPath.getValue());
assertTrue(x.length() > 0);
ManagedProperty libraryPath = mo.getProperty("libraryPath");
x = (String) metaValueFactory.unwrap(libraryPath.getValue());
assertTrue(x.length() > 0);
ManagedProperty managementSpecVersion = mo.getProperty("managementSpecVersion");
x = (String) metaValueFactory.unwrap(managementSpecVersion.getValue());
assertEquals(mbean.getManagementSpecVersion(), x);
ManagedProperty specName = mo.getProperty("specName");
x = (String) metaValueFactory.unwrap(specName.getValue());
assertEquals(mbean.getSpecName(), x);
ManagedProperty specVendor = mo.getProperty("specVendor");
x = (String) metaValueFactory.unwrap(specVendor.getValue());
assertEquals(mbean.getSpecVendor(), x);
ManagedProperty specVersion = mo.getProperty("specVersion");
x = (String) metaValueFactory.unwrap(specVersion.getValue());
assertEquals(mbean.getSpecVersion(), x);
ManagedProperty vmName = mo.getProperty("vmName");
x = (String) metaValueFactory.unwrap(vmName.getValue());
assertEquals(mbean.getVmName(), x);
ManagedProperty vmVendor = mo.getProperty("vmVendor");
x = (String) metaValueFactory.unwrap(vmVendor.getValue());
assertEquals(mbean.getVmVendor(), x);
ManagedProperty vmVersion = mo.getProperty("vmVersion");
x = (String) metaValueFactory.unwrap(vmVersion.getValue());
assertEquals(mbean.getVmVersion(), x);
ManagedProperty startTime = mo.getProperty("startTime");
long time = (Long) metaValueFactory.unwrap(startTime.getValue());
assertTrue(time > 10000000);
ManagedProperty uptime = mo.getProperty("uptime");
time = (Long) metaValueFactory.unwrap(uptime.getValue());