1   /*
2    * $Id: MuleAdminAgentTestCase.java 7963 2007-08-21 08:53:15Z dirk.olmes $
3    * --------------------------------------------------------------------------------------
4    * Copyright (c) MuleSource, Inc.  All rights reserved.  http://www.mulesource.com
5    *
6    * The software in this package is published under the terms of the CPAL v1.0
7    * license, a copy of which has been included with this distribution in the
8    * LICENSE.txt file.
9    */
10  
11  package org.mule.impl.internal.admin;
12  
13  import org.mule.MuleManager;
14  import org.mule.tck.AbstractMuleTestCase;
15  
16  public class MuleAdminAgentTestCase extends AbstractMuleTestCase
17  {
18  
19      /**
20       * Print the name of this test to standard output.
21       */
22      protected void doSetUp() throws Exception
23      {
24          getManager(false);
25      }
26  
27      public void testEmptyServerUrl() throws Exception
28      {
29          final String serverEndpoint = "";
30          MuleManager.getConfiguration().setServerUrl(serverEndpoint);
31          MuleAdminAgent agent = new MuleAdminAgent();
32          agent.initialise();
33  
34          // if it doesn't here fail, it has been registered
35      }
36  
37      public void testNonEmptyServerUrl() throws Exception
38      {
39          final String serverEndpoint = "test://12345";
40          MuleManager.getConfiguration().setServerUrl(serverEndpoint);
41          MuleAdminAgent agent = new MuleAdminAgent();
42          agent.initialise();
43  
44          // if it doesn't here fail, it has been registered
45      }
46  
47  }