1 17 package org.apache.servicemix.jbi.management.task; 18 19 import javax.jbi.management.DeploymentServiceMBean; 20 21 import org.apache.servicemix.jbi.framework.AdminCommandsServiceMBean; 22 import org.apache.tools.ant.Project; 23 24 25 30 public class JbiTaskTest extends JbiTaskSupport { 31 32 private JbiTask jbiTask; 33 34 37 protected void setUp() throws Exception { 38 super.setUp(); 39 jbiTask = new JbiTask(){ 40 protected void doExecute(AdminCommandsServiceMBean acs) throws Exception { 41 } 42 }; 43 jbiTask.setProject(new Project()); 44 jbiTask.init(); 45 jbiTask.connect(); 46 } 47 48 51 protected void tearDown() throws Exception { 52 jbiTask.close(); 53 super.tearDown(); 54 } 55 56 public void testGetDeploymentService() throws Exception { 57 DeploymentServiceMBean mbean = jbiTask.getDeploymentService(); 58 assertNotNull(mbean); 59 mbean.getDeployedServiceAssemblies(); 60 } 61 62 public void testGetAdminCommandsService() throws Exception { 63 AdminCommandsServiceMBean mbean = jbiTask.getAdminCommandsService(); 64 assertNotNull(mbean); 65 } 66 } 67 | Popular Tags |