@Test
public void testRegisterService() {

    dsm.startup();
    String name = "myNewService";
    dsm.registerService(name, "AZ");
    String service = dsm.getServiceByName(name, String.class);
    assertNotNull(service);
    assertEquals("AZ", service);
    try {
        dsm.registerService("fakey", (Object)null);
        fail("should have thrown exception");
    } catch (IllegalArgumentException e) {
        assertNotNull(e.getMessage());
    }
}