28293031323334353637
public class EJBLocatorFactoryTest { @Test public void testGetEJBLocator() { EJBLocator locator = EJBLocatorFactory.getEJBLocator(); assertNotNull(locator); assertTrue(locator.getClass().getName(), locator instanceof OpenEJBLocator); }
59606162636465666768
return super.loadClass(className); } }.loadClass(EJBLocatorFactory.class.getName()); EJBLocator locator = (EJBLocator) elf.getMethod("getEJBLocator").invoke(null); assertNotNull(locator); assertTrue(locator.getClass().getName(), locator instanceof EJBLocationUnavailable); }
3839404142434445464748
@Before public void setup() { modeller = new EJBModeller(); EJBLocator locator = Skeleton.newMock(EJBLocator.class); modeller.setLocator(locator); ejbLocator = Skeleton.getSkeleton(locator); bundleLocation = Skeleton.newMock(IDirectory.class);