1 23 24 29 package com.sun.enterprise.management.base; 30 31 import java.util.Set ; 32 33 import javax.management.ObjectName ; 34 import javax.management.MBeanServerConnection ; 35 import javax.management.AttributeList ; 36 import javax.management.MBeanInfo ; 37 import javax.management.MBeanAttributeInfo ; 38 import javax.management.MBeanOperationInfo ; 39 40 import com.sun.appserv.management.base.NotificationServiceMgr; 41 import com.sun.appserv.management.base.NotificationService; 42 import com.sun.appserv.management.base.Util; 43 44 45 import com.sun.enterprise.management.AMXTestBase; 46 import com.sun.enterprise.management.Capabilities; 47 48 50 public final class NotificationServiceMgrTest extends AMXTestBase 51 { 52 public 53 NotificationServiceMgrTest( ) 54 { 55 } 56 57 public static Capabilities 58 getCapabilities() 59 { 60 return getOfflineCapableCapabilities( true ); 61 } 62 public void 63 testGet() 64 { 65 assert( getNotificationServiceMgr() != null ); 66 } 67 68 public void 69 testCreateRemove() 70 throws Exception 71 { 72 final NotificationServiceMgr proxy = getNotificationServiceMgr(); 73 74 final NotificationService service = proxy.createNotificationService( "test1", 512 ); 75 76 final ObjectName objectName = Util.getObjectName( service ); 77 78 proxy.removeNotificationService( service.getName() ); 79 assert( ! getConnection().isRegistered( objectName ) ); 80 } 81 82 83 } 84 85 86 | Popular Tags |